Jump to content

Extra Info Block in all products


Recommended Posts

Hi, I am trying to find out how can I add one text to all products within a specific category or all categories at the same time? does it have anything to do with the product.tpl file? or is there any module for that?

 

Your answers are much appreciated

Link to comment
Share on other sites

If your txt is th same for all products, go to line495 of product.tpl, you'll find this:

 

<ul id="more_info_tabs" class="idTabs idTabsShort clearfix">
 {if $product->description}<li><a id="more_info_tab_more_info" href="#idTab1">{l s='More info'}</a></li>{/if}
 {if $features}<li><a id="more_info_tab_data_sheet" href="#idTab2">{l s='Data sheet'}</a></li>{/if}
 {if $attachments}<li><a id="more_info_tab_attachments" href="#idTab9">{l s='Download'}</a></li>{/if}
 {if isset($accessories) AND $accessories}<li><a href="#idTab4">{l s='Accessories'}</a></li>{/if}
 {if isset($product) && $product->customizable}<li><a href="#idTab10">{l s='Product customization'}</a></li>{/if}
 {$HOOK_PRODUCT_TAB}
</ul>

Add another <li> after hook_product_tab, but inside the ul.

 

Make sure the ahref send you to the same ID you will use for the tab (like #idTab22)

Then, at line (well, it was before, will be 1 line after if you added the li into a new line) 642, you'll find:

{if isset($HOOK_PRODUCT_TAB_CONTENT) && $HOOK_PRODUCT_TAB_CONTENT}{$HOOK_PRODUCT_TAB_CONTENT}{/if}

 

After it, add something like

 

<div id="idTab22" class="rte">
 <h3>A title</h3>
<p>{l s='my content...'}</p>
</div>

 

Again, this will be th same for all products

Link to comment
Share on other sites

Aw, i thought you mean a tab by extra info, for that line 431, before this

  {if (!$allow_oosp && $product->quantity <= 0) OR !$product->available_for_order OR (isset($restricted_country_mode) AND $restricted_country_mode) OR $PS_CATALOG_MODE}
   <span class="exclusive">
 <span></span>
 {l s='Add to cart'}
   </span>
  {else}
   <p id="add_to_cart" class="buttons_bottom_block">
 <span></span>
 <input type="submit" name="Submit" value="{l s='Add to cart'}" class="exclusive" />
   </p>
  {/if}

Link to comment
Share on other sites

×
×
  • Create New...