zoukankan
html css js c++ java
新闻图片效果
<
SCRIPT language
=
JavaScript
>
var
imgUrl
=
new
Array();
var
imgLink
=
new
Array();
var
imgText
=
new
Array();
var
picNum
=
0
;
imgUrl[
1
]
=
"
images/aa01.jpg
"
;
//
如果想在要图片上显示可以点击链接,把下注示去掉即可
//
imgLink[1]="http://www.foundertech.com";
imgUrl[
2
]
=
"
images/aa07.jpg
"
;
//
imgLink[2]="http://www.foundertech.com";
imgUrl[
3
]
=
"
images/aa11.jpg
"
;
//
imgLink[3]="http://www.founder.com/qywh.htm";
imgUrl[
4
]
=
"
images/aa14.jpg
"
;
//
imgLink[4]="http://card.foundertech.com/live/shucu/index.htm";
imgUrl[
5
]
=
"
images/aa15.jpg
"
;
//
imgLink[5]="http://www.foundertech.com/sales_pro/0706bijiben/index.html";
function
NextPic()
{
if
(picNum
<
5
) picNum
++
;
else
picNum
=
1
;
if
(document.all)
{
document.imgInit.filters.revealTrans.Transition
=
Math.floor(Math.random()
*
23
);
document.imgInit.filters.revealTrans.apply(); document.imgInit.filters.revealTrans.play();
}
document.images.imgInit.src
=
imgUrl[picNum];
//
document.all.hlkImg.href="javascript:goUrl();";
focustext.innerHTML
=
'
<
a href
=/
'
+
imgLink[picNum]
+
' target
=
_blank
>
'
+
imgText[picNum]
+
'
</
a
>
';
theTimer
=
setTimeout('NextPic()',
3000
); }
function
goUrl()
{ window.open(imgLink[picNum],'_blank');
}
</
SCRIPT
>
<
TABLE
>
<
TBODY
>
<
TR
>
<
TD align
=
"
right
"
><
A id
=
hlkImg
name
=
hlkImg
><
IMG id
=
imgInit
style
=
"
FILTER: revealTrans(duration=2,Transition=5)
"
width
=
"
195px
"
height
=
"
255px
"
border
=
0
name
=
imgInit
></
A
></
TD
></
TR
>
<
TR style
=
"
DISPLAY: none
"
>
<
TD align
=
middle height
=
"
10px
"
>
<
DIV id
=
focustext align
=
center name
=
"
focustext
"
style
=
"
14px;height:10px
"
></
DIV
>
<
SCRIPT language
=
JavaScript
>
NextPic();
</
SCRIPT
>
</
TD
></
TR
></
TBODY
></
TABLE
>
<!--
动态显示图片方法一end
-->
<!--
动态显示图片方法二开始
-->
<
SCRIPT language
=
javascript type
=
""
>
//
Set slideShowSpeed (milliseconds)
var
slideShowSpeed
=
5000
;
//
Duration of crossfade (seconds)
var
crossFadeDuration
=
3
;
//
Specify the image files
var
Pic
=
new
Array();
//
to add more images, just continue
//
the pattern, adding to the array below
Pic[
0
]
=
'images
/
aa11.jpg'
Pic[
1
]
=
'images
/
aa07.jpg'
Pic[
2
]
=
'images
/
aa14.jpg'
Pic[
3
]
=
'images
/
aa15.jpg'
Pic[
4
]
=
'images
/
aa01.jpg'
//
do not edit anything below this line
var
t;
var
j
=
0
;
var
p
=
Pic.length;
var
preLoad
=
new
Array();
for
(i
=
0
; i
<
p; i
++
)
{
preLoad[i]
=
new
Image();
preLoad[i].src
=
Pic[i];
}
function
runSlideShow()
{
if
(document.all)
{
document.images.SlideShow.style.filter
=
"
blendTrans(duration=2)
"
;
document.images.SlideShow.style.filter
=
"
blendTrans(duration=crossFadeDuration)
"
;
document.images.SlideShow.filters.blendTrans.Apply();
}
document.images.SlideShow.src
=
preLoad[j].src;
if
(document.all)
{
document.images.SlideShow.filters.blendTrans.Play();
}
j
=
j
+
1
;
if
(j
>
(p
-
1
)) j
=
0
;
t
=
setTimeout('runSlideShow()', slideShowSpeed);
}
</
SCRIPT
>
<
img src
=
"
javascript:runSlideShow()
"
name
=
'SlideShow' width
=
"
195px
"
height
=
"
255
"
border
=
"
0
"
align
=
"
right
"
>
<!--
动态显示图片方法一END
-->
查看全文
相关阅读:
Spring 发生 has not been refreshed yet 异常
rsyslog config
grok
阿里云态势
Unity的asm笔记
Unity2020或Unity2019安装后无法启动
rider代码折叠
使用rider调试lua
MacType更好的字体渲染
Unity字体和画面花屏处理
原文地址:https://www.cnblogs.com/voidxy/p/980679.html
最新文章
flask 静态文件配置
flask_restful 接收post参数,返回json
ajax 获取接口返回值
https网站解决block:mixed-content问题
HTML5将footer置于页面最底部的方法(CSS+JS)
树莓派搭建自己的MQTT服务器
centos7 搭建mqtt服务器
python3 flask 微信公众号消息接收测试代码
flask 渲染拼接模版
python3 进程状态
热门文章
Python3 Socket与Socket心跳机制简单实现
线程初始化
Process calling
python3 进程调用
python 路径拼接
python3 获取当前日期时间字符串
Python writelines()函数
python3 接收html页面上传的文件
Linux常用命令--清屏
ORA-00257: 归档程序错误。在释放之前仅限于内部连接
Copyright © 2011-2022 走看看