New tab for the product details page

To add a new tab to the product details page:
  1. Open the products.php file located in the include/customer directory of your CS-Cart.
  2. Replace this part of the code:
    $product_tabs = array (
            'description' => array ('name' => fn_get_lang_var('description')),
        );

    with this one:
    $product_tabs = array (
            'description' => array ('name' => fn_get_lang_var('description')),
            'tab1' => array ('name' => 'YOUR_TAB_NAME'),
        );

    where YOUR_TAB_NAME is the name of your tab.
  3. Save the file.
  4. Open the product_details.tpl file in the skins/[CUSTOMER_ACTIVE_SKIN]/customer/product_pages directory of your CS-Cart installation, where [CUSTOMER_ACTIVE_SKIN] is an active skin of your storefront.
  5. Add the following part of the code there:
    <div id="content_tab1">
    YOUR TAB CONTENT HERE
    </div>

    below for example this part of the code:
    {if $product.image_pairs}
    <div id="content_images">
        {include file="products_pages/additional_images.tpl" product=$product show_detailed_link="Y"}
    </div>
    {/if}
  6. Save the file.

Noticed an error in the article or it is not clear enough? Any suggestions to improve it? Please let us know by filling in the feedback form. Click here.