Jump to content

[solved]How to add a new field on product page


Recommended Posts

Hi,

How can I add a new field on product page?

I have: Quantity
Availability

Under availability i need to add "Free Delilvery!". This shoud appear on all products pages - I offer free delivery for all my products.

I tried on product.tlp but.. no success..

Please help!


sorry for bad english..

Link to comment
Share on other sites

Change lines 271-276 of product.tpl from:

<!-- number of item in stock -->

quantity == 0} style="display:none;"{/if}>
{$product->quantity|intval}
quantity > 1} style="display:none;"{/if} id="quantityAvailableTxt">{l s='item in stock'}
quantity == 1} style="display:none;"{/if} id="quantityAvailableTxtMultiple">{l s='items in stock'}



to:

<!-- number of item in stock -->

quantity == 0} style="display:none;"{/if}>
{$product->quantity|intval}
quantity > 1} style="display:none;"{/if} id="quantityAvailableTxt">{l s='item in stock'}
quantity == 1} style="display:none;"{/if} id="quantityAvailableTxtMultiple">{l s='items in stock'}



{l s='Free Shipping!'}

Link to comment
Share on other sites

not working..
also, my product.tlp is different:

<!-- number of item in stock -->

quantity == 0)} style="display:none;"{/if}>
quantity > 1} style="display:none;"{/if} id="quantityAvailableTxt">{l s='Produs in stoc :'}
quantity < 2} style="display:none;"{/if} id="quantityAvailableTxtMultiple">{l s='Produse in stoc :'}
{$product->quantity|intval}

    

{l s='Free Shipping!'}        

Link to comment
Share on other sites

I'm not sure why it isn't working for you. It's working on my PrestaShop v1.3.5 test site. I even tried copying your code above and it worked too on my website. The only reasons I can think that it isn't working is that your product.tpl file has been cached and isn't refreshing, or you have third-party CSS hiding the text.

Link to comment
Share on other sites

  • 2 weeks later...
×
×
  • Create New...