adknath Posted June 13, 2020 Share Posted June 13, 2020 Hi, please I will like to add some custom fields to my products details page beneath the condition. How can I get it done? Thanks in advance... Link to comment Share on other sites More sharing options...
prestamonste Posted June 13, 2020 Share Posted June 13, 2020 Hi there, In this case, you need to change your theme. Step 1: Open product.tpl file (via ftp, or cpanel): public_html/themes/your_current_theme/templates/catalog/product.tpl Step 2: Add the title of the tab Product customization EX: theme classic: go to line code 172 add this pieces code: {if $product.is_customizable && count($product.customizations.fields)} <li class="nav-item"> <a class="nav-link" data-toggle="tab" href="#customizations" role="tab" aria-controls="customizations">{l s='Product customization' d='Shop.Theme.Catalog'}</a> </li> {/if} Step 3: Add the content of tab Product customization {* Add the content of tab Product customization*} <div class="tab-pane fade in" id="customizations" role="tabpanel"> {if $product.is_customizable && count($product.customizations.fields)} {block name='product_customization'} {include file="catalog/_partials/product-customization.tpl" customizations=$product.customizations} {/block} {/if} </div> {* End of add the content of tab Product customization*} Step 4: Remove old code of Product customization Hope it helpful. Link to comment Share on other sites More sharing options...
adknath Posted June 14, 2020 Author Share Posted June 14, 2020 On 6/13/2020 at 10:30 AM, prestamonste said: Hi there, In this case, you need to change your theme. Step 1: Open product.tpl file (via ftp, or cpanel): public_html/themes/your_current_theme/templates/catalog/product.tpl Step 2: Add the title of the tab Product customization EX: theme classic: go to line code 172 add this pieces code: {if $product.is_customizable && count($product.customizations.fields)} <li class="nav-item"> <a class="nav-link" data-toggle="tab" href="#customizations" role="tab" aria-controls="customizations">{l s='Product customization' d='Shop.Theme.Catalog'}</a> </li> {/if} Step 3: Add the content of tab Product customization {* Add the content of tab Product customization*} <div class="tab-pane fade in" id="customizations" role="tabpanel"> {if $product.is_customizable && count($product.customizations.fields)} {block name='product_customization'} {include file="catalog/_partials/product-customization.tpl" customizations=$product.customizations} {/block} {/if} </div> {* End of add the content of tab Product customization*} Step 4: Remove old code of Product customization Hope it helpful. Thank you, I appreciate you effort... Link to comment Share on other sites More sharing options...
philipp.haugg Posted June 15, 2020 Share Posted June 15, 2020 Hi, You can also use the paid module to achieve the same. https://addons.prestashop.com/en/search?search_query=ADDITIONAL FIELDS 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