LLLLLLL Posted February 1, 2013 Share Posted February 1, 2013 I'm having a conflict between jQuery versions or something, I get Property '$' of object [object Window] is not a function I've read about using $.noConflict() or other potential fixes but I cannot get any solution to work. The working page is http://americangene.com/checkout/ -- the problem is between the cart's jQuery and the jQuery in use by the WordPress template. Any suggestions are welcome. Quote Link to comment https://forums.phpfreaks.com/topic/273908-need-help-with-property-of-object-object-window-is-not-a-function/ Share on other sites More sharing options...
Adam Posted February 1, 2013 Share Posted February 1, 2013 Take a look at line 447 of the source for that link. The WordPress JS is making the call to noConflict(), meaning the $ reference has been removed when your code runs at document ready. Quote Link to comment https://forums.phpfreaks.com/topic/273908-need-help-with-property-of-object-object-window-is-not-a-function/#findComment-1409530 Share on other sites More sharing options...
LLLLLLL Posted February 1, 2013 Author Share Posted February 1, 2013 Ok, but does this mean, I guess, that I need to add something at the bottom of all the script? And what? I very much appreciate it. Quote Link to comment https://forums.phpfreaks.com/topic/273908-need-help-with-property-of-object-object-window-is-not-a-function/#findComment-1409532 Share on other sites More sharing options...
Adam Posted February 1, 2013 Share Posted February 1, 2013 You either need to remove the noConflict() call, or reference jQuery the standard way: jQuery('...'); Quote Link to comment https://forums.phpfreaks.com/topic/273908-need-help-with-property-of-object-object-window-is-not-a-function/#findComment-1409534 Share on other sites More sharing options...
LLLLLLL Posted February 1, 2013 Author Share Posted February 1, 2013 Yeah, the "standard way" isn't an option with this silly theme. I removed noConflict and cleaned up a couple other things. Working now. Thank you. Quote Link to comment https://forums.phpfreaks.com/topic/273908-need-help-with-property-of-object-object-window-is-not-a-function/#findComment-1409535 Share on other sites More sharing options...
.josh Posted February 2, 2013 Share Posted February 2, 2013 why don't you just upgrade to the latest jQuery and use only one instance of it? Quote Link to comment https://forums.phpfreaks.com/topic/273908-need-help-with-property-of-object-object-window-is-not-a-function/#findComment-1409646 Share on other sites More sharing options...
LLLLLLL Posted February 2, 2013 Author Share Posted February 2, 2013 Well as I said before, the "standard way" or "right way" is not an option here. There are two different technologies on one page, and they each have their own stuff going on. I'm not a fan of these cookie-cutter theme things that require so much nonsense (when CSS is truly all that was needed). But this topic is solved. Quote Link to comment https://forums.phpfreaks.com/topic/273908-need-help-with-property-of-object-object-window-is-not-a-function/#findComment-1409649 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.