会员
周边
众包
新闻
博问
闪存
赞助商
所有博客
当前博客
我的博客
我的园子
账号设置
简洁模式
...
退出登录
注册
登录
nasdaqhe's blog
被生活强jian着
博客园
::
首页
::
新随笔
::
联系
::
订阅
::
管理
公告
javascript图片渐变轮换效果
Posted on
2006-10-27 16:54
nasdaqhe
阅读(
3173
) 评论(
2
)
编辑
收藏
举报
<
html
>
<
head
>
<
title
>
图片渐变轮换效果
</
title
>
<
meta name
=
"
generator
"
content
=
"
editplus
"
>
<
meta name
=
"
author
"
content
=
"
5dshow.com
"
>
</
head
>
<
body
>
<
p
>
图片渐变轮换效果(IE),请等几秒钟看效果
</
p
>
<
a href
=
"
#
"
id
=
"
javascript.a
"
><
img src
=
"
UploadFiles/2006-6/69311881.jpg
"
id
=
"
javascript.img
"
border
=
0
style
=
"
filter:blendTrans(duration=2)
"
width
=
"
240
"
height
=
"
180
"
></
a
>
<
script
>
<!--
var
ImgSrc
=
new
Array();
//
图片地址
ImgSrc[
0
]
=
"
UploadFiles/2006-6/69846915.jpg
"
ImgSrc[
1
]
=
"
UploadFiles/2006-7/73557027.jpg
"
ImgSrc[
2
]
=
"
UploadFiles/2006-7/73557027.jpg
"
ImgSrc[
3
]
=
"
UploadFiles/2006-7/79256345.jpg
"
for
(
var
i
=
0
;i
<
ImgSrc.length;i
++
)
{(
new
Image()).src
=
ImgSrc[i];}
//
预加载图片
var
ImgAlt
=
new
Array();
//
鼠标放上去显示的文字
ImgAlt[
0
]
=
"
合纵堂相簿1
"
ImgAlt[
1
]
=
"
合纵堂相簿2
"
ImgAlt[
2
]
=
"
合纵堂相簿3
"
ImgAlt[
3
]
=
"
合纵堂相簿4
"
var
ImgHerf
=
new
Array();
//
链接
ImgHerf[
0
]
=
"
0/5dshow/archives/2006/200669165010.html
"
ImgHerf[
1
]
=
"
0/5dshow/archives/2006/200669165010.html
"
ImgHerf[
2
]
=
"
0/qiaomai/archives/2006/200673211517.html
"
ImgHerf[
3
]
=
"
0/qiaomai/archives/2006/200679131446.html
"
var
step
=
0
;
function
slideit()
{
var
oImg
=
document.getElementById(
"
javascript.img
"
);
if
(document.all)
{oImg.filters.blendTrans.apply();}
oImg.src
=
"
ImgSrc[step]
"
;
document.getElementById(
"
javascript.a
"
).href
=
"
ImgHerf[step]
"
;
oImg.title
=
ImgAlt[step];
if
(document.all)
{oImg.filters.blendTrans.play();}
step
=
(step
<
(ImgSrc.length
-
1
))
?
(step
+
1
):
0
;
(
new
Image()).src
=
ImgSrc[step];
//
加载下一个图片
}
setInterval(
"
slideit()
"
,
3000
);
//
-->
</
script
>
</
body
>
</
html
>
会员力量,点亮园子希望
刷新页面
返回顶部
Powered by:
博客园
Copyright © 2024 nasdaqhe
Powered by .NET 8.0 on Kubernetes