Need to add script immediately before
-
I need to add a simple script to reverse the action of a plugin only on one or a few pages (it is active site wide). The plugin author recommends modifying the footer.php, but I would prefer not to do this. Using your plugin, I am able to inject this script intended to “hide” the plugin. But it does not load last, immediately before </body>. In fact, a few other theme scripts run (Avada theme) and then the plugin script runs. So it is literally the last thing loaded before the </body>. And the plugin remains active as it is the last script run.
The script is:
jQuery(document).ready(function($) {jQuery(“#sss-sidebar-source-div-1”).smartTabDrawer(“hide”);});Is there a way force it to a lower priority or a way to force it to load last? The page is here: https://www.rosssolargroup.com/friends/ (NOTE: I have deliberately used bad code to cause the plugin to “break” on the page. Same result as effectively hiding it.)
Thanks! John
- The topic ‘Need to add script immediately before’ is closed to new replies.