<%
set rs=server.CreateObject("adodb.recordset")
rs.Open "select * from advertisement",conn,1,1
tupian1=trim(rs("pic1"))
tupian1url=trim(rs("pic1_lnk"))
piaos1=trim(rs("tit1"))

tupian2=trim(rs("pic2"))
tupian2url=trim(rs("pic2_lnk"))
piaos2=trim(rs("tit2"))

tupian3=trim(rs("pic3"))
tupian3url=trim(rs("pic3_lnk"))
piaos3=trim(rs("tit3"))

tupian4=trim(rs("pic4"))
tupian4url=trim(rs("pic4_lnk"))
piaos4=trim(rs("tit4"))
 
tupian5=trim(rs("pic5"))
tupian5url=trim(rs("pic5_lnk"))
piaos5=trim(rs("tit5"))
rs.Close
set rs=nothing
  
%>
<div align="center">
 
  	  <script language="" type="text/javascript">
	<!--
imgUrl1="<%=tupian1%>";
imgtext1=""
imgLink1=escape("<%=tupian1url%>");
imgUrl2="<%=tupian2%>";
imgtext2=""
imgLink2=escape("<%=tupian2url%>");
imgUrl3="<%=tupian3%>";
imgtext3=""
imgLink3=escape("<%=tupian3url%>");
imgUrl4="<%=tupian4%>";
imgtext4=""
imgLink4=escape("<%=tupian4url%>");
imgUrl5="<%=tupian5%>";
imgtext5=""
imgLink5=escape("<%=tupian5url%>");

	var focus_width=540
	var focus_height=185
	var text_height=0
	var swf_height = focus_height+text_height
	
	 var pics=imgUrl1+"|"+imgUrl2+"|"+imgUrl3+"|"+imgUrl4+"|"+imgUrl5
 var links=imgLink1+"|"+imgLink2+"|"+imgLink3+"|"+imgLink4+"|"+imgLink5
 var texts=imgtext1+"|"+imgtext2+"|"+imgtext3+"|"+imgtext4+"|"+imgtext5
 	
	document.write('<object ID="focus_flash" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" width="'+ focus_width +'" height="'+ swf_height +'">');
	document.write('<param name="allowScriptAccess" value="sameDomain"><param name="movie" value="images/pixviewer.swf"><param name="quality" value="high"><param name="bgcolor" value="#AFDBFE">');
	document.write('<param name="menu" value="false"><param name=wmode value="opaque">');
	document.write('<param name="FlashVars" value="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'">');
	document.write('<embed ID="focus_flash" src="images/pixviewer.swf" wmode="opaque" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'" menu="false" bgcolor="#5A9FB5" quality="high" width="'+ focus_width +'" height="'+ swf_height +'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');		
	document.write('</object>');
	
	//-->
	
</script>