[wp-hackers] Remove wp_enqueue_style called mid-page

Andrew Nacin wp at andrewnacin.com
Wed Mar 26 16:02:46 UTC 2014


If you simply enqueue it in time for the header, it should print in the
header and not print it again in the footer.


On Wed, Mar 26, 2014 at 11:58 AM, Dino Termini <dino at duechiacchiere.it>wrote:

> Hi all,
>
> I am using a plugin that does a wp_enqueue_style mid-page, instead of
> using the appropriate hook. This causes the CSS to be added to the footer,
> which I would like to avoid.
>
> Aside from contacting the plugin author, is there a way to dequeue that
> style so that I can enqueue it in the header? I would like to avoid editing
> the plugin's source code to comment out that line of code ;)
>
> I've tried a bunch of combinations of actions/dequeue/deregister, to no
> avail.
>
> Thanks,
> Dino.
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>


More information about the wp-hackers mailing list