Support

Account

Home Forums General Issues Moving css & js to the footer: incompatibility

Solving

Moving css & js to the footer: incompatibility

  • Hi folks,

    I’m using the theme Newspaper by tagDiv: http://themeforest.net/item/newspaper/5489609

    Their theme includes a speed-boosting plugin that mainly moves css and js to the footer queue to speed up rendering. They have it switch itself off in the presence of all but a few plugins they’ve tested, but I decided to try it out. I did get some css loading breaking, and after deactivating all plugins and reactivating them one by one, I’ve narrowed it down to ACF PRO (v5.3.3.2).

    I’m guessing this is unavoidable, but just for my curiosity and to guide further probing, can you think of anything in ACF that would be conflicting with that functionality?

    Thanks!

  • Hi @themediumutm

    Could you please tell me how it breaks? Maybe you can share some screenshots?

    Maybe that plugin has a feature to exclude ACF’s CSS files?

    Thanks!

  • Thanks for the reply. On reading over the code I’m pretty sure it does the following:

    — Unregisters theme and any recommended plugins’ css and reregisters at the bottom
    — Same for the js
    — Same for jquery itself

    Since the first two only affects specific named styles and scripts, I assume jquery might have an interaction with ACF. Not sure what, though…

    But to answer your question: I realized that all the missing styles are just from the theme’s css itself. (This appears to be dynamically generated since you can insert custom css in their theme settings page.) So I’m not even sure how ACF would be interacting with that.

    My solution was just to comment out the line where they move their own css. Everything else on the site appears to be functioning normally. If I find out anything else I’ll update this thread. 🙂

Viewing 3 posts - 1 through 3 (of 3 total)

The topic ‘Moving css & js to the footer: incompatibility’ is closed to new replies.