Jump to content

Archived

This topic is now archived and is closed to further replies.

Inbound Horizons Inc.

pl.helpers.js Error On DMS 2

Recommended Posts

Inbound Horizons Inc.

Hi, one of our newer DMS2 install sites is having periodic JS conflict issues. The site is here: www.sanantoniomobilehomes.com and the code in conflict is on pl.helpers.js at line 569, error reads 'cannot read property 'activeClass' of undefined' and my guess is the $menu variable is returning empty for some reason. This breaks the nav bar mega menu set up, and of course all the JS on the page in the sections below. This is the only site I have right now using the mega menu in DMS 2, and the only one having this issue. 

 

I deactivated all plugins, even cleared out all custom CSS for a time, it did not resolve it. There is a third-party tracking script (tracking.callmeasurement.com) that was loading in the head on the site as well that I suspected might be causing the issue, erasing it seemed to resolve the issue at times. However it is now set up correctly to load using wp_enqueue_script in the lowest load priority in the footer after anything related to DMS loads, but the pl.helpers.js script that loads before this script is still having the same issues.  However, the strange thing is it only happens occasionally, and then self-corrects after about an hour. Everything will run fine, and then it will break on Safari but work on Chrome, and then a while later work on Safari, Firefox, IE but break on Chrome at the same time, leading me to think it may be a browser/cookie issue. 

 

Screenshot from Chrome dev panel is attached. 

 

Has anyone dealt with this same bug using the DMS2 mega menu? If so how did you fix it? If not, any suggestions, other than just not using the mega menu option? Any suggestions on a better load option for the script possibly causing the conflict to de-conflict it? The standard practice I am familiar with is using wp_enqueue and changing the load priority that way, but if any devs have other suggestions I'd appreciate it. 

 

 

Share this post


Link to post
Share on other sites
Danny

Hi,

 

When I use a vanilla DMS setup i.e. latest WordPress/DMS and no custom code or plugins, I have no issue with the MegaMenu. Therefore, as you pointed out the issue is with the script you're using. I think the best course of action would be to contact the author of the script ask them for support, especially with you saying it corrects itself after a period of time.

 

Also, the site you link doesn't load ?


Please search our forums, before posting!

Share this post


Link to post
Share on other sites
Inbound Horizons Inc.

Danny - 

 

Thanks for the reply, sorry for the typo on the URL (www.sanantoniomobilehomes.com) in the original post, I fixed it. Yeah, of course first thing was to contact the company that provides the script likely causing the issue, I've actually been working with them off and on for over a month, with no real resolution as they don't seem to know why it would be causing the conflict, and in turn essentially point their finger at the theme being the issue and needing the fix. I'm caught in the middle, well aware of the actual root of the issue, but no one seems to know how to correct it, and was hoping perhaps you would have some insights on any best practices for de-conflicting JS conflicts with DMS and possibly some specifics with the megamenu issue. I know standard practices like enqueuing the script, etc... But any suggestions from you all on what could be tried further for DMS would be appreciated, your team is usually pretty insightful on these kinds of things. 

Share this post


Link to post
Share on other sites
Danny

I am unable to tell you whats wrong, if you have enqueued the script using the WordPress function and are still having issues, then you need to speak to the script author. DMS works out of the box without any JS conflict or error and the megamenu has no problem either.


Please search our forums, before posting!

Share this post


Link to post
Share on other sites
Inbound Horizons Inc.

Alright, appreciate your time Danny, I'll put the ball back in the tracking script author's court there. 

 

Share this post


Link to post
Share on other sites

  • Similar Content

    • Lisa Haran
      By Lisa Haran+
      Hi 
      I have a map here http://www.iloveoffset.com/maps/
      I want to add several pointer locations to the map, but when I do they do not appear.
      On this map there are 2 pointer locations and as you can there is only one visible.
      Earlier today I added 7 and could only see 4 so there is something odd going on.
      My theme is up to date
    • clj182
      By clj182+
      Hello,
      I've been having trouble unlocking the template section for past couple of weeks. When I try clicking nothing happens. 
      I've deleted my custom css and removed plugins. Im down to having only the following plugins:
      Akismet
      Contact Form 7
      DMS Professional Tools
      Pagelines Updater
      WooCommerce
      It was working fine before i have no idea what's going on with it.
    • flourishdesignstudio
      By flourishdesignstudio+
      My DMS 2 site http://www.heart-stone.com/ will not save any new custom css... I can still edit templates and publish those but any custom css that I enter never saves.
      All WP files, themes, and plugins are up to date. 
      Any thought about what might be causing this?
    • flourishdesignstudio
      By flourishdesignstudio+
      Is there a way to edit the custom CSS via FTP? I know I can edit the custom code in the Chrome editor but is there a file path I can use to find and edit the CSS directly from our FTP?
      Thanks in advance for the help!
    • nizami
      By nizami+
      Using navbar section with correctly configured WP menu to display main navigation at https://elenaangel.com. 
      All fine in desktop viewport. Menu displays twice in hamburger mode. How to fix this please? 

×