JavaScript 일정시간마다 이미지 변경되는 소스
페이지 정보
본문
<div id="TopBanner" style="width:420;height:200;filter:blendTrans(duration=1); overflow: hidden;">
<img border="0" src="images/spacer.gif" /></div>
<script language="JavaScript" type="text/javascript">
<!--
var itv = 4000;
var BannerArray = new Array ();
BannerArray[0] = "<a href='http://dizin.co.kr/acc_r/tri/t50/01.htm'><img src='http://dizin.co.kr/main2/data/20070319101756ban.jpg' border=0></a>";
BannerArray[1] = "<a href='/event/03/01/01.htm'><img src='http://dizin.co.kr/main2/data/20070315194003index.gif' border=0></a>";
BannerArray[2] = "<a href='http://dizin.co.kr/dica_r/olympus/fe240/01.htm'><img src='http://dizin.co.kr/main2/data/20070322171742ban.jpg' border=0></a>";
BannerArray[3] = "<a href='http://dizin.co.kr/board/zboard.php?id=photo_essay&page=1&sn1=&divpage=1&sn=off&ss=on&sc=on&select_arrange=headnum&desc=asc&no=147'><img src='http://dizin.co.kr/main2/data/200703231058360323.jpg' border=0></a>";
BannerArray[4] = "<a href='http://dizin.co.kr/dica_r/sigma/sd14_1/01.htm'><img src='http://dizin.co.kr/main2/data/20070317132144ban.jpg' border=0></a>";
BannerArray[5] = "<a href='http://dizin.co.kr/dica_r/olympus/sp550uz/01.htm'><img src='http://dizin.co.kr/main2/data/20070319192646ban.jpg' border=0></a>";
BannerArray[6] = "<a href='/dica_r/samsung/nv3_s/01.htm'><img src='http://dizin.co.kr/main2/data/20070312123858banner.jpg' border=0></a>";
BannerArray[7] = "<a href='http://dizin.co.kr/acc_r/bag/13029/01.htm'><img src='http://dizin.co.kr/main2/data/20070322172513ban.jpg' border=0></a>";
function blendbanner()
{
if (navigator.appName!="Netscape") document.all.TopBanner.filters.blendTrans.apply();
if(navigator.appName=="Netscape" && document.getElementById) document.getElementById("TopBanner").innerHTML=BannerArray[n];
else document.all.TopBanner.innerHTML=BannerArray[n];
if (navigator.appName!="Netscape") document.all.TopBanner.filters.blendTrans.play();
}
function BannerRotate()
{
if(!n) n=0;
blendbanner();
n++;
if(n>=BannerArray.length) n = 0
setTimeout("BannerRotate()",itv);
}
function changeBanner(no)
{
n = no; blendbanner();
}
setTimeout("BannerRotate()",100);
changeBanner(0);
-->
</script>
<img border="0" src="images/spacer.gif" /></div>
<script language="JavaScript" type="text/javascript">
<!--
var itv = 4000;
var BannerArray = new Array ();
BannerArray[0] = "<a href='http://dizin.co.kr/acc_r/tri/t50/01.htm'><img src='http://dizin.co.kr/main2/data/20070319101756ban.jpg' border=0></a>";
BannerArray[1] = "<a href='/event/03/01/01.htm'><img src='http://dizin.co.kr/main2/data/20070315194003index.gif' border=0></a>";
BannerArray[2] = "<a href='http://dizin.co.kr/dica_r/olympus/fe240/01.htm'><img src='http://dizin.co.kr/main2/data/20070322171742ban.jpg' border=0></a>";
BannerArray[3] = "<a href='http://dizin.co.kr/board/zboard.php?id=photo_essay&page=1&sn1=&divpage=1&sn=off&ss=on&sc=on&select_arrange=headnum&desc=asc&no=147'><img src='http://dizin.co.kr/main2/data/200703231058360323.jpg' border=0></a>";
BannerArray[4] = "<a href='http://dizin.co.kr/dica_r/sigma/sd14_1/01.htm'><img src='http://dizin.co.kr/main2/data/20070317132144ban.jpg' border=0></a>";
BannerArray[5] = "<a href='http://dizin.co.kr/dica_r/olympus/sp550uz/01.htm'><img src='http://dizin.co.kr/main2/data/20070319192646ban.jpg' border=0></a>";
BannerArray[6] = "<a href='/dica_r/samsung/nv3_s/01.htm'><img src='http://dizin.co.kr/main2/data/20070312123858banner.jpg' border=0></a>";
BannerArray[7] = "<a href='http://dizin.co.kr/acc_r/bag/13029/01.htm'><img src='http://dizin.co.kr/main2/data/20070322172513ban.jpg' border=0></a>";
function blendbanner()
{
if (navigator.appName!="Netscape") document.all.TopBanner.filters.blendTrans.apply();
if(navigator.appName=="Netscape" && document.getElementById) document.getElementById("TopBanner").innerHTML=BannerArray[n];
else document.all.TopBanner.innerHTML=BannerArray[n];
if (navigator.appName!="Netscape") document.all.TopBanner.filters.blendTrans.play();
}
function BannerRotate()
{
if(!n) n=0;
blendbanner();
n++;
if(n>=BannerArray.length) n = 0
setTimeout("BannerRotate()",itv);
}
function changeBanner(no)
{
n = no; blendbanner();
}
setTimeout("BannerRotate()",100);
changeBanner(0);
-->
</script>
댓글목록
등록된 댓글이 없습니다.