Jump to content

Uncaught TypeError checkboxChange is not a function


Recommended Posts

Hi,

My shop is built with Prestahsop 1.5.6.2

In the browser console, js tab, I can see the following error :
cart-summary.js:835 Uncaught TypeError: $(...).checkboxChange is not a function
    at HTMLDocument.<anonymous> (../js/cart-summary.js:835)
    at o (../xxxxxxxxxxxxx.js:2)
    at Object.fireWith (../xxxxxxxxxxxxx.js:2)   
    at Function.ready (../xxxxxxxxxxxxx.js:2)
    at HTMLDocument.B (../xxxxxxxxxxxxx.js:2)

The line 835 to 843 of the js/cart-summary.js file are the following :


    $('#gift').checkboxChange(function() { $('#gift_div').show('slow'); }, function() { $('#gift_div').hide('slow'); });
    $('#enable-multishipping').checkboxChange(
        function() {
            $('.standard-checkout').hide(0);
            $('.multishipping-checkout').show(0);
        },
        function() {
            $('.standard-checkout').show(0);
            $('.multishipping-checkout').hide(0);

Such error only displays on category and product-list pages, but not on product pages.

1- Would you know what is the purpose of the checkboxChange function ?

2- How to avoid this error ?


I thank you in advance for any reply.

Patrick

Link to comment
Share on other sites

It's odd it displays on category pages actually, it should only trigger in the checkout. Anyway that's not a core jquery function, it must be some plugin (though google doesn't seem to know it?) or something made by the theme developer. Is it a paid theme?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...