Rebel Tech Posted July 4, 2016 Share Posted July 4, 2016 Morning Morning Any chance anyone has a solution: I am trying to change the Product Reference on the Product Page from the product_reference to product_id. The original code in theme/mytheme/product.tpl <p id="product_reference"{if empty($product->reference) || !$product->reference} style="display: none;"{/if}> <label>{l s='Reference:'} </label> <span class="editable" itemprop="sku">{if !isset($groups)}{$product->reference|escape:'html':'UTF-8'}{/if}</span> </p> I changed it to <p id="product_id"{if empty($product->id) || !$product->id} style="display: none;"{/if}> <label>{l s='Reference:'} </label> <span class="editable" itemprop="sku">{if !isset($groups)}{$product->id|escape:'html':'UTF-8'}{/if}</span> </p> However the reference shows as blank now. Any advise? Link to comment Share on other sites More sharing options...
im_presto Posted July 4, 2016 Share Posted July 4, 2016 Don't use escape string function on integer. Link to comment Share on other sites More sharing options...
Rebel Tech Posted July 4, 2016 Author Share Posted July 4, 2016 (edited) Don't use escape string function on integer. Still getting blank when I use integer <p id="product_id"{if empty($product->id) || !$product->id} style="display: none;"{/if}> <label>{l s='Reference:'} </label> <span class="editable" itemprop="sku">{if !isset($groups)}{$product->id}{/if}</span> </p> Edited July 4, 2016 by Rebel Tech (see edit history) Link to comment Share on other sites More sharing options...
im_presto Posted July 4, 2016 Share Posted July 4, 2016 Hi, You can turn on debug mode to see the error on that page. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now