shopping cart templates, oscommerce templates, cre loaded 
templates, zencart templates, magento templates

Ecommerce Products KnowledgeBase

shopping cart templates, oscommerce templates, cre loaded 
templates, zencart templates, magento templates

Adding hide_add_to_cart function for CreLoaded B2B template OS03C00317

Print | Bookmark
Bookmark and Share

Adding hide_add_to_cart function for CreLoaded B2B template OS03C00317

1. In your az_pl_src_cre_317.php add this line:

    $hide_add_to_cart = hide_add_to_cart(); 

2. Then add attributes to the xml at line 913 - 925, add this one

    $response .= '<add_to_cart><![CDATA['.$hide_add_to_cart.']]></add_to_cart>'."\n";

3. In your /templates/OS03C00317/includes/js/pl.core.js add this below line 96 where the values of xml where initiated.

    pl_data[i]['add_to_cart'] = $("add_to_cart", this).text() ? $("add_to_cart", this).text() : 0;

4. In your pl.view.js add a condition before you display your add to cart button in both list and grid view the condition should be:

     if(!add_to_cart){
....code to display the add to cart button
}

Was this article helpful?

Yes No
Bookmark and Share

Category: CRELOADED

23257 views