• I’m sorry I’m not the best with PHP at all.

    Trying to get this to work but I seem to have something wrong?

    Can aNybody help with what I am missing?

    function cegg_savings() { ?>
    
    <?php if ($perc_difference && $min_price_item['domain'] != $max_price_item['domain']): ?>, <?php echo sprintf(__('which is %s%% less than the cost in %s (%s).', 'content-egg-tpl'), $perc_difference, $shops_list[$max_price_item['domain']], TemplateHelper::formatPriceCurrency($max_price_item['price'], $max_price_item['currencyCode'])); ?>
    
      <?php
      }
    
    add_action( 'woocommerce_single_product_summary', 'cegg_savings', 10 );
    • This topic was modified 5 years, 10 months ago by Jan Dembowski.
Viewing 1 replies (of 1 total)
  • It might help if you explain what you are trying to do or what error you are getting, but you should do it at the support forum for the plugin you are using. I can’t tell if that’s Woocommerce itself or some other plugin that adds functionality to it.

Viewing 1 replies (of 1 total)

The topic ‘Php Functions Issue’ is closed to new replies.