Cyber Week Sale! Get $20 off GP Premium, $40 off our new Lifetime license, and 45% off license renewals/extensions! Learn more

[Resolved] Adding call tracking script breaks mobile menu

Home Forums Support Adding call tracking script breaks mobile menu

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #160817
    Eric

    Hi Tom,

    I love your theme, I use it as often as possible. However, I’ve run into a problem that’s happening on several sites now.

    We do call tracking and in order to do so, I simply add a JS file just below the closing body tag. Adding the script causes the mobile menu to not expand.

    Right now I have it enqueued in the functions file. But I’ve also tried adding it as a Hook. I think either way is fine. But the problem happens regardless.

    So far to troubleshoot, I have disabled all plugins, upgraded the theme, upgraded GP Premium, upgraded all plugins. I’ve enabled WP-DEBUG and cleared up any errors.

    Unfortunately I’m stumped and not sure what the issue is, or how to resolve. I was wondering if you might be able to take a look.

    Thank you so much,
    Eric

    #160818
    Tom
    Lead Developer
    Lead Developer

    If adding the script causes the menu not to expand, it typically means there’s a javascript error in the script you’re using which is preventing the rest of the javascript on the site to execute.

    Can you link me to your site possibly?

    #161158
    Eric Bunch

    Hi Tom,

    I sent the information you requested via your contact form.

    Thank you,
    Eric

    #161203
    Tom
    Lead Developer
    Lead Developer

    I don’t believe I received anything from you? Can you try again and reference this topic?

    Thanks!

    #161466
    Eric Bunch

    Hi Tom,

    I suspect by now that my second contact form submission failed. I’ll just go ahead and post the link: http://philadelphiadentist.com

    The script that is enqueued in the functions file that is causing the mobile menu not to expand is:

    <script type=’text/javascript’ src=’https://pistonbroke.com/ct/referrer_dynjs.php?c_id=71&ver=0.1.0′></script&gt;

    The script does work, because when you reload the page – you can see the phone number quickly change. So it’s weird that interferes with the mobile menu.

    I appreciate you taking a peek and for any insight you may have.

    Thanks,
    Eric

    #161481
    Tom
    Lead Developer
    Lead Developer

    Hi Eric,

    Interesting – it works when you resize your browser down to mobile size, but won’t work on my Android.

    Can you show me the code you’re using to enqueue it? We should be able to make it show up after the mobile navigation script, which should fix it.

    Let me know 🙂

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.