Product Page Tabs Instructions

Installation

Disable compiler

System > Tools > Compilation page and click on Disable button. After Installation you can enable compilation back.

Install extension archive Sashas_Producttabs.tgz and Sashas_Baseext.tgz from admin System->Magento Connect-> Magento Connect Manager after that choose package from folder and upload it.

 

Usage:

The product page should have code which is same as in base template to make tabs work propertly.You cna file product page at base package or your theme at following path:

/app/design/frontend/{your_package}/{your_theme}/templates/catalog/product/list.phtml or /app/design/frontend/base/default/templates/catalog/product/view.phtml

In case your product page in base default folder you can copy it into same path (if fodlers not exist - create them) at your template

At the end of the file check that you have this lines:

   
<?php foreach ($this->getChildGroup('detailed_info', 'getChildHtml') as $alias => $html):?>
"> <?php if ($title = $this->getChildData($alias, 'title')):?>

<?php echo $this->escapeHtml($title); ?>

<?php endif;?> <?php echo $html; ?>
<?php endforeach;?> <<?php echo $this->getChildHtml('upsell_products') ?> <?php echo $this->getChildHtml('product_additional_data') ?>

This lines used for tabs. In case you want add new tab you need add it inside

block. Example code of additional tab (Replace {tabname} with any uniq tab id):

            

Title of Tab/h2>

Tab Text

Complete code with new tabs will looks like:

   
<?php foreach ($this->getChildGroup('detailed_info', 'getChildHtml') as $alias => $html):?>
"> <?php if ($title = $this->getChildData($alias, 'title')):?>

<?php echo $this->escapeHtml($title); ?>

<?php endif;?> <?php echo $html; ?>
<?php endforeach;?> <<?php echo $this->getChildHtml('upsell_products') ?> <?php echo $this->getChildHtml('product_additional_data') ?>

Title of Tab/h2>

Tab Text

If you need to take out one of the existing options from tabs you need take code out of

block.

 

Usage of js options:

For generation of the tabs used prototype js script. The initilization file located at: /skin/frontend/base/default/js/producttabs/tabs.js

There you can pay attention on 15 line:

new Control.Tabs('product-tabs',{CreateTabs:1,TitleClass: 'product-tab'});

If you want to hide labels in tabs like "Decription" or "Tags" you need add parameter ShowTitle:0 . With this parameter it will look:

new Control.Tabs('product-tabs',{CreateTabs:1,TitleClass: 'product-tab', ShowTitle:0});

Parameters CreateTabs:1,TitleClass: 'product-tab' are required.

More information about other parameters you can find at plugin page

 

Css modification:

Css style for tabs located at /skin/frontend/base/default/css/producttabs/tabs.css

if you need make changes better copy it in same folder in your tempalte path instead base/default and make changes there. This way after update of the extension changes will not be overwritten.