• Hi there,

    I have noticed that some plugins insert CSS into the head of the page rather than using a CSS file.

    Is there an easy way to stop this happening or removing the CSS and placing it in an external file?

    Thanks

    • This topic was modified 6 years, 4 months ago by Jan Dembowski. Reason: Moved to Fixing WordPress, this is not an Developing with WordPress topic
Viewing 3 replies - 1 through 3 (of 3 total)
  • @thetoolman123 some more advanced caching plugins might be able to do that for you.

    However, if it’s not a lot of CSS, why bother?

    Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    >> some plugins << It’s up to the plugin author whether to put CSS inline or enqueue a CSS file.

    Plugins like “autoptimize” can combine/collect CSS and put it all inline or into one or more cached and minified files.

    Moderator bcworkz

    (@bcworkz)

    The way to do so depends on how it got there to start with. If accomplished through a filter or action hook like it is supposed to be done, you can add code to remove the callback soon after it has been added. To do so you would need to find the code where it was added in order to have the proper parameters for removal. If you have trouble finding such code, you can try asking that plugin’s devs through their official support channel.

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

The topic ‘Removing CSS from index page’ is closed to new replies.