Support » Plugin: Autoptimize » Facebook Pixel Tracking not working with AO

  • Resolved hifunda

    (@hifunda)



    Hi,

    Great plugin so far in helping me to improve my page speeds!

    But I am having trouble with my contact form 7 submissions not consistently firing a Lead event in the FB Pixel Helper Chrome extension, and most plugin support authors are pointing to your AutoOptimize plugin killing off some Javascript, or some conflict that breaks JS code.

    Basically, it works correctly only when I flush the AO cache or disable both this plugin and Fastest Cache plugin. I am optimizing for all 3 settings – HTML, CSS and Javascript and excluding jquery as you suggested in another reply.

    My page is at: https://chennaidreamhomes.com/contact/
    Can you help?

    Thanks,
    Tara

    The page I need help with: [log in to see the link]

Viewing 11 replies - 1 through 11 (of 11 total)
  • Plugin Author Optimizing Matters

    (@optimizingmatters)

    Hi again Tara;
    I had a look at your site and I see that:
    * you’re also using WP Fastest Cache’s minification features, this makes breakage more likely so disable all of WPFC’s minifiction when using AO
    * you don’t have AO JS optimization active now, but I do see JS errors on the browser console:

    TypeError: a.widget is not a function[Learn More] mouse.min.js:11:161
    TypeError: c is not a constructor[Learn More] widget.min.js:11:705
    ReferenceError: Clipboard is not defined[Learn More] sassy-social-share-public.js:827:6

    you’ll have to fix these as these will break the entire Autoptimized JS-file
    * you’re also using something (a plugin?) to async your JS, this makes breakage more likely so disable at least until you found & fixed your root cause problem

    hope this helps,
    frank

    Hi Frank,

    1.

    you’re also using WP Fastest Cache’s minification features, this makes breakage more likely so disable all of WPFC’s minifiction when using AO

    Can you help with which exact options I should uncheck in WP Fastest Cache since AutoOptimize is already minifying HTML, CSS and Javascript right now: https://prnt.sc/gt4ill

    2. I am using Async Javascript plugin along with AutOptimize for a further boost in page speed which has helped, as lots of people have suggested. Somehow, just Fastest Cache and AutoOptimize together dont help me cache enough and get my site speed down. If not, feel free to tell me which ideal combination of settings across these plugins will help my site’s performance.

    Thanks,
    Tara

    • This reply was modified 1 year, 1 month ago by  hifunda.
    Plugin Author Optimizing Matters

    (@optimizingmatters)

    sure, untick;
    * minify HTML
    * combine CSS
    * minify CSS
    * combine JS
    * minify JS

    1. Ok I unchecked those minify options and also deactivated Async Javascriopt plugin without any site speed issues and now the pixel seems to be firing correctly 🙂 But I still have not been able to see ther Pixel Event Activity in my Ads Manager: https://prnt.sc/gt50wt

    2. I was using Async Javascript plugin along with AutOptimize for a further boost in page speed which has helped, as lots of people have suggested. Somehow, just Fastest Cache and AutoOptimize together didn’t help me cache enough and get my site speed down. If not, feel free to tell me which ideal combination of settings across these plugins will help my site’s performance.

    • This reply was modified 1 year, 1 month ago by  hifunda.
    Plugin Author Optimizing Matters

    (@optimizingmatters)

    Regarding the use of async js; first make sure everything works without it, then you can try re-enabling it. if things continue to work; great 🙂

    Regarding the event firing twice; no idea I’m afraid. As the FB-tracking JS is inline and isn’t affected by Autoptimize, I don’t think this is due to AO really …

    frank

    Yes I have checked on reactivating Async Javascript plugin and it still works so the issue must have been duplicate minification from AO and Fastest Cache.

    Thanks Frank!

    But how can I improve my score on Defer parsing of JavaScript and Leverage browser caching scores in GTMetrix. Site speed has indeed gone down.

    • This reply was modified 1 year, 1 month ago by  hifunda.
    Plugin Author Optimizing Matters

    (@optimizingmatters)

    had a quick look at your gtmetrix result; all of the “leverage browser caching” warnings are for external files (e.g. facebook/ twitter/ google maps/ …), do you can’t fix except by removing (some of) those that I’m afraid.

    frank

    Ok I understand that, thanks but what do other websites also using such services usually do to resolve this? Surely it can’t be to stop using them! 🙂

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    Surely it can’t be to stop using them!

    That’s the only solution I know of, sorry 🙂

    Ok I found it did not work properly again with Async Javascript enabled so have disabled it for now.

    Thanks Frank!
    Closing this now.

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    you’re welcome Tara 🙂

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘Facebook Pixel Tracking not working with AO’ is closed to new replies.