jquery这款图片延迟加载功能太漂亮了,对于大网站可以节省不少的宽带,现在很多商城都是这样做的,如果taobao,moko等网站。
<!doctype html public "-//w3c//dtd xhtml 1.0 transitional//en" "http://www.w3.org/tr/xhtml1/dtd/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><head>
<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
<title></title>
<meta name="generator" content="mephisto" />
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js" type="text/网页特效" charset="utf-8"></script>
<script src="jquery.lazyload.js" type="text/javascript" charset="utf-8"></script>
<script type="text/javascript" charset="utf-8">
$(function() {
$("img").lazyload({
placeholder : "grey.gif",
effect : "fadein"
});
});
</script>
<style type="text/css教程">
#sidebar {
width: 0px;
}#content {
width: 770px;
}</style>
</head>
<body>
<div class="entry">
<img src="../demo1.jpg" width="765" height="574"><br/>
<img src="../demo2.jpg" width="765" height="574"><br/>
<img src="../demo3.jpg" width="765" height="574"><br/>
<img src="../demo4.jpg" width="765" height="574" ><br/>
<img src="../demo5.jpg" width="765" height="574"><br/>
<img src="../demo6.jpg" width="765" height="574" ><br/>
</div>
</body>
</html>