预加载器在asp.net中加载页面后不隐藏。我试过两个javascript代码。但没有帮助。
Xaml代码 -
<script type="text/javascript">
jQuery(window).load(function () { // makes sure the whole site is loaded
jQuery("#status").fadeOut(); // will first fade out the loading animation
jQuery("#preloader").delay(1000).fadeOut("slow"); // will fade out the white DIV that covers the website.
})
</script>
<body >
<div id="preloader">
<div id="status"> </div>
</div>
Coding...
Xaml代码 -
<script type="text/javascript">
function hide_preloader() {
$("#preloader").fadeOut(100);
}
</script>
<body onload="hide_preloader();" >
<div id="preloader">
<div id="status"> </div>
</div>
..CODEING...
图像
答案 0 :(得分:1)
尝试
jQuery(document).ready(function () { // makes sure the whole site is loaded
jQuery("#status").fadeOut(); // will first fade out the loading animation
jQuery("#preloader").delay(1000).fadeOut("slow"); // will fade out the white DIV that covers the website.
});