<%
'Flash幻灯图片产品（新闻）调用
'调用方式<!--#include file="pic_news.asp"-->
'ProductShow.asp?ID=显示内容的网页
%>


<%
        set rs_news_pic=server.createobject("adodb.recordset")
       	rs_news_pic.open "select top 5 * from Product where Passed=True and IncludePic=True order by ID desc ",conn,1,1
       
       	pic=rs_news_pic("DefaultPicUrl")
       	link=rs_news_pic("ID")
       	texts=trim(rs_news_pic("title"))
       
       	rs_news_pic.movenext
       	do while not rs_news_pic.eof
     	pic=pic&"|"&rs_news_pic("DefaultPicUrl")
       	link=link&"|"&"ProductShow.asp?ID="&rs_news_pic("ID")
       	texts=texts&"|"&trim(rs_news_pic("title"))
       	rs_news_pic.movenext
       	loop
   
       	rs_news_pic.close
       	set rs_news_pic=nothing%>
		<BODY BGCOLOR=#FFFFFF text="#000000" LEFTMARGIN=0 TOPMARGIN=0 >

<table width="260" border="0" cellspacing="0" cellpadding="0" align="center" height="190"> 
<tr> <td height="190" align="center" class="16" valign="middle" width="260"> 
	<script type="text/javascript">
	<!--
	
	var focus_width=260
	var focus_height=187
	var text_height=20
	var swf_height = focus_height+text_height
	
	
	var pics='<%=pic%>'
	var links='ProductShow.asp?ID=<%=link%>'
	var texts='<%=texts%>'	
	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="flash/pixviewer.swf"><param name="quality" value="high"><param name="bgcolor" value="#ffffff">');
	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="flash/pixviewer.swf" wmode="opaque" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'" menu="false" bgcolor="#ffffff" 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>
</td></tr> 
</table>