var buttonX;
var buttonY;
var bakularCode="";
var adNum=0;
var dakularCode="";
var theTimer;
var imgPre=new Array();
for (i=1;i<10;i++)
{
imgPre[i]=new Image();
imgPre[i].src=imgUrl[i];
}
function setTransition()
{
if (document.all)
{
imgUrlrotator.filters.revealTrans.Transition=23;
imgUrlrotator.filters.revealTrans.apply();
}
}
function playTransition()
{
if (document.all)
imgUrlrotator.filters.revealTrans.play()
}
function nextAd(toNum)
{
if(adNum<imgUrl.length-1)
adNum++ ;
else
adNum=1;
if(toNum!=null) adNum=toNum;
setTransition();
document.images.imgUrlrotator.src=imgUrl[adNum];
document.getElementById('linktext').innerHTML=imgTz[adNum];
document.images.imgUrlrotator.alt='ÉÌ³ÇÍÆ¼ö£º'+imgTz[adNum];
document.getElementById('linktext').innerHTML="<a href="+imgLink[adNum]+" class=px14-lh20>"+imgTz[adNum]+"</a>"; 
playTransition();
checkButton();
if(toNum!=null)
{toNum=null;theTimer=setTimeout("nextAd()", 7000);}
else
{theTimer=setTimeout("nextAd()", 7000);}
}
function jump2url()
{
jumpUrl=imgLink[adNum];jumpTarget='_blank';
if (jumpUrl != '')
{ if (jumpTarget != '')
window.open(jumpUrl,jumpTarget);
else location.href=jumpUrl;
}
}
function displayStatusMsg()
{
status=imgLink[adNum];
document.returnValue = true;
}
function checkButton()
{
for(i=1;i<=imgUrl.length-1;i++)
{if(i==adNum)
eval("bt"+i+".style.backgroundColor='#9B0000';bt"+i+".style.color='#FFFFFF';");
else
eval("bt"+i+".style.backgroundColor='#CCCCCC';bt"+i+".style.color='#000000';");
}
}
function dakularButtons()
{

buttonX=600-imgUrl.length*20;buttonY=182;
for(i=1;i<=imgUrl.length-1;i++)
{
dakularCode=dakularCode+"<div id='bt"+i+"' style='display:inline; height=15px; width:20px; border:1px solid #FFFFFF; background-color:#f7f7f7; color:#000000; font-size:12px; line-height:14px; filter:Alpha(Opacity=50, FinishOpacity=50,Style=2);' align='center' onMouseOver=this.style.backgroundColor='#FFFFFF';this.style.color='#000000';this.style.cursor='hand' onMouseOut=checkButton(); onClick='clearTimeout(theTimer);nextAd("+i+");'>"+i+"</div>";
}
dakularCode="<div style='display:inline; position:absolute; left:"+buttonX+"px; top:"+buttonY+"px; z-index:1;'>"+dakularCode+"</div>";
document.write(dakularCode);

}
document.write ('<table border="0" cellpadding="0" cellspacing="0" id=newsTable style="position:relative; top:0px;right:0px; font-size:12px;">');
document.write ('<tr><td><a onMouseOver="displayStatusMsg();return document.returnValue;" onMouseOut=status=""; href="javascript:jump2url()">');
document.write ('<img style="FILTER: revealTrans(duration=1,transition=18);" src="javascript:nextAd()" width=580 height=180 border=0 name=imgUrlrotator></a>');
dakularButtons();
document.write ('</td></tr><tr><td class="cartshow0" style="height:20">&nbsp;<label id="linktext"></label></td></tr></table>');