我正在使用 MSdropdown,一切正常,cookies 和所有!但是,当我加载站点时,msdropdown 框需要几秒钟的时间才能加载,并且在加载时会在显示完全加载之前显示选择选项框。请你看看我的编码并告诉我哪里出错了?检查我的网站,看看我的意思是用你自己的眼睛...... www.cig-go.com
谢谢
<select id="webmenu" onchange="document.cookie= 'myDDIdx = ' + this.selectedIndex + '; path=/;'; window.open(this.options[this.selectedIndex].value,'_top')">
<option value="select currency" >Change Currency</option>
<option value="http://www.cig-go.com/?setCurrencyId=2" title="https://www.cig-go.com/product_images/uploaded_images/Pound.png">Pound</option>
<option value="http://www.cig-go.com/?setCurrencyId=4" title="http://www.cig-go.com/product_images/uploaded_images/Euro.png">Euro</option>
<option value="http://www.cig-go.com/?setCurrencyId=3" title="http://www.cig-go.com/product_images/uploaded_images/Dollar.png">Dollar</option>
</select>
<script type="text/javascript">
var sidx = document.cookie.indexOf("myDDIdx");
if(sidx != -1)
window.onload = function () { document.getElementById("webmenu").selectedIndex = document.cookie.substr(sidx + 8,1); }
(document).ready(function(e) {
try {
("body select").msDropDown();
} catch(e) {
alert(e.message);
}
});
</script>
我也在 html head 中得到了这个:
<script src="http://www.cig-go.com/content/msdropdown/msdropdown/jquery-1.3.2.min.js" type="text/javascript"></script>
<script src="http://www.cig-go.com/content/msdropdown/msdropdown/jquery.dd.min.js" type="text/javascript"></script>
<link rel="stylesheet" type="text/css" href="http://www.cig-go.com/content/msdropdown/msdropdown/dd.css" />
<script src="http://www.cig-go.com/content/100/cookies.js" ></script>
<script>
$(document).ready(function () {
$("select").msDropDown();
});
</script>
任何帮助都会非常感激,我对此感到很困惑,请帮助。它可能只需要你一秒钟 :) 谢谢