[wordpress]テーマ内でwp_enqueue_scriptを使用したいとき

ど忘れして、結構な時間探してしまった。。。

 

wp_enqueue_script('name',get_bloginfo('template_url') . '/●●●/●●●.js');

Jquery使うときはこっち

wp_enqueue_script('name',get_bloginfo('template_url') . '/●●●/●●●.js', array(jquery), '1.1');

 

[jquery]クリックでアクティブ追加

他のメニューをクリックした場合は解除の後、クラス追加

<script type="text/javascript">

jQuery(document).ready(function(){

$("#navigation li").click(
function(){
$("#navigation li").removeClass('active');
$(this).addClass("active");
}
);
});

</script>


Warning: file_get_contents(https://api.instagram.com/v1/users/6994864344/media/recent/?access_token=6994864344.13cb8de.f5d29d8d0edd42d884d39d2dba128922) [function.file-get-contents]: failed to open stream: HTTP request failed! HTTP/1.1 400 Bad Request in /home/users/0/icurus.jp-silva/web/caramu.com/wp-content/themes/caramu_wp/home.php on line 42

Warning: array_merge() [function.array-merge]: Argument #2 is not an array in /home/users/0/icurus.jp-silva/web/caramu.com/wp-content/themes/caramu_wp/home.php on line 52

Warning: Invalid argument supplied for foreach() in /home/users/0/icurus.jp-silva/web/caramu.com/wp-content/themes/caramu_wp/home.php on line 56

Warning: krsort() expects parameter 1 to be array, null given in /home/users/0/icurus.jp-silva/web/caramu.com/wp-content/themes/caramu_wp/home.php on line 65

Warning: Invalid argument supplied for foreach() in /home/users/0/icurus.jp-silva/web/caramu.com/wp-content/themes/caramu_wp/home.php on line 69