Load plugin files and code conditionally
-
Hi there,
this is a great plugin. I am so happy that things like this are available for free. π Thank you Pupunzi!
I am wondering if there is any way to load the js and the css code conditionally, meaning only when there is actually an mp3 link in the page or maybe in dependency of a custom field value?
I have only one page with mp3 files on my site but the player files are loaded on every page which makes the loading of pages slower without any benefit. It would be great if there is an option for it in the plugin settings or another way to actually check if the plugin files are actually needed on a page/post.
Or maybe as a work-around, it there a way to unregister the scripts in the functions.php?
The topic ‘Load plugin files and code conditionally’ is closed to new replies.