$(document).ready(function(){
var ScreenSizeHis = $.cookie(ScreenSizeHis);
$("#arrow").bind('click', function(){
$('#naviclosed').fadeIn("fast");
$(window).unbind('resize');
});
$('#naviclosed').bind('click', function () {
$('#naviclosed').fadeOut("fast");
if ((ScreenSizeHis = $.cookie('ScreenSizeHis')) != undefined) {
$(window).bind('resize', ScreenSize);
}
});
});
$(window).resize(function() {
ScreenSize();
});
$(document).ready(function() {
windowwidth = $(window).width();
if (windowwidth < 1040) {
$('#naviclosed').fadeIn("fast");
}
if (windowwidth >= 1040) {
$('#naviclosed').fadeOut("fast");
}
});
function ScreenSize() {
windowsize = $(window).width();
if (windowsize < 1040) {
$('#naviclosed').fadeIn("fast");
}
if (windowsize >= 1040) {
$('#naviclosed').fadeOut("fast");
}
}
好的,在我放入 cookie 插件后,这些按钮甚至都不起作用。