Do I have this code written correctly?



Where in the heck do I put it? The instructions say: "To customize other aspects of the cart, just add the following lines of code to your View Cart code on every page, just before the // --> line in the standard code you obtained from Seller Admin. "

However there is no //--> in the standard code... Help!



function EJEJC_config() {

jQuery("#btnCC").attr("src", "http://www.blah-blah.com/wp-content/uploads/2013/10/CheckOut-Neue-cc.gif");

EJEJC_POSTCALL=true;

}

  • created

    Oct '13
  • last reply

    Oct '13
  • 1

    reply

  • 1.2k

    views

  • 2

    users

  • 1

    link

You need to use the code from your View Cart button, not from the Add to Cart buttons.



The View Cart button code is consistent across your entire account and is available on the same screen where you get your Add to Cart buttons. This code contains the javascript which actually creates the customizable overlay cart and it is required for any customizations to work.



Your custom code is a little bit out of order and incomplete, it should read as follows:



function EJEJC_config() {

EJEJC_POSTCALL=true;

}

function EJEJC_shown() {

jQuery("#btnCC").attr("src", "http://www.blah-blah.com/wp-content/uploads/2013/10/CheckOut-Neue-cc.gif");

}



The above should be copied just before the //--> line in the View Cart button. It will replace our free checkout button with your own image, only in those cases where the cart total is $0.