wp_enqueue_script
-
The story:
I’m using child theme based on buddypress.
I have a javascript which need to interact with parent theme’s js functions. So, I copied parent’s global.js into child theme folder, edited and loaded up in child them.
The situation:
The same js file is loaded by child’s function.php, and loaded again by parent’s function.php, through “wp_enqueue_script”
The reason I believe it’s been double loaded is– “wp_enqueue_script” can be used more than once in a theme.
The question:
How can I let WP know not to laod the js file in parent’s function.php ?Thanks for helping in advance!
Regards
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘wp_enqueue_script’ is closed to new replies.