Loaded JavaScript file not showing [duplicate]

If the files show up in the html source then there is something wrong with your javascript (it may even be as simple as missing a semicolon in the wrong place). Without further information we can’t help you. Beware that wordpress loads jquery in no conflict mode so the function call is jQuery() and not … Read more

Trigger a function during onload

Enqueue your script only when the page you want it on is requested: function wpa_script() { if( is_page( ‘global-network’ ) ){ wp_enqueue_script( ‘wpa_script’, get_template_directory_uri() . ‘/js/my_worldmap.js’, array(‘jquery’) ); } } add_action( ‘wp_enqueue_scripts’, ‘wpa_script’ ); See is_page() in Codex.