How to Resolve JS Waypoints Conflict?
After updating Anspress and Categories for Anspress, our site is rendered useless. Most content doesn’t show up and there seems to be a huge conflict with our theme/Visual Composer.
This is the error we get:
Uncaught Error: The sticky method does not exist in jQuery Waypoints.
Any help you could provide would be great.
I think its happening due to name conflict
wp_enqueue_script('waypoints', ap_get_theme_url('js/jquery.waypoints.min.js'), 'jquery', AP_VERSION);
find above in
anspress-question-answer/theme/default/function.php
and replace it with:
wp_enqueue_script('ap_waypoints', ap_get_theme_url('js/jquery.waypoints.min.js');
I have added ap_ prefix.
If you don’t mind share your link.
Rahul Aryan commented
its okey if it fixed your issue.
I replaced the old code with
wp_enqueue_script( ‘ap_waypoints’, ap_get_theme_url(‘js/jquery.waypoints.min.js’), ‘jquery’, AP_VERSION);
and that seemed to fix it.
This site is hosted internally for our company so I cannot post the URL.
Thanks!