サイトで jquery を使用するインスタンス (画像スライダーやナビゲーションなど) が複数ありますが、jquery 呼び出しを複数回行わないと機能しません。
たとえば、以下の 2 つのスニペットは、スクリプトを 2 回呼び出さない限り機能しません。助けてください。(私のページには、別のライブラリを呼び出すだけでなく、より多くのjquery呼び出しがあります)最新のライブラリを一度呼び出すだけで完了できませんか?試してみましたが、うまくいきません。
<!--menu -->
<script type="text/javascript" src="js/jquery.min.js"></script>
<link rel="stylesheet" type="text/css" href="css/newnav.css" />
<script type="text/javascript" src="js/navdoublecolumn.js"></script>
<script>
<!--
ddmegamenu.docinit({
menuid:'solidmenu',
dur:0,
easing:'easeInOutCirc' //<--no comma after last setting
})
// -->
</script>
<!-- slide -->
<script type="text/javascript" src="js/jquery.min.js"></script>
<script src="js/jquery.tabSlideOut.v1.3.js"></script>
<script type="text/javascript">
$(function(){
$('.slideout1').tabSlideOut({
tabHandle: '.slideouthandle1', //class of the element that will become your tab
pathToTabImage: 'images/slideouttab_chat.jpg',//path to the image for the tab //Optionally can be set using css
imageHeight: '150px', //height of tab image //Optionally can be set using css
imageWidth: '40px', //width of tab image //Optionally can be set using css
tabLocation: 'left', //side of screen where tab lives, top, right, bottom, or left
speed: 200, //speed of animation
action: 'click', //options: 'click' or 'hover', action to trigger animation
topPos: '215px', //position from the top/ use if tabLocation is left or right
leftPos: '20px', //position from left/ use if tabLocation is bottom or top
fixedPosition: true //options: true makes it stick(fixed position) on scroll
});
});
</script>