主题:  求助:关于图片渐显JS效果+FLASH的问题

asstudio

职务:普通成员
等级:1
金币:0.0
发贴:4
#12006/10/25 12:58:46
就是这个代码:关于图片渐显JS效果+FLASH的
我把图片地址、链接地址、和新闻标题都用ASP代码替换为动态以后,在最后总有一副图片不能显示出来,我自己看应该是图片地址动态输出后,在最后多了一个|的问题。请教各位该如何解决!~


这个是源来的代码 !
<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>网页特效|Linkweb.cn/Js|---可控制的用FLASH控件实现的图片渐显JS效果</title>
</head>

<body>
<SCRIPT type=text/javascript>
	<!--
	
	var focus_width=257
	var focus_height=192
	var text_height=20
	var swf_height = focus_height+text_height
	
	var pics='Images/test001.jpg|Images/test002.jpg|Images/test003.jpg|Images/test004.jpg|Images/test004.jpg'
	var links='http://linkweb.cn/Js/Js.asp?ID=535|http://linkweb.cn/Js/Js.asp?ID=518|http://linkweb.cn/Js/Js.asp?ID=497|http://linkweb.cn/Js/Js.asp?ID=480|http://linkweb.cn/Js/Js.asp?ID=480'
	var texts='FLASH图片渐显效果测试|这种效果到底是怎么实现的呢|现在估计是JS和FLASH共同作用|那个FLASH文件应该是控制文件|现在估计是JS和FLASH共同作用'
	
	document.write('<object 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/flash01.swf"><param name="quality" value="high"><param name="bgcolor" value="#F0F0F0">');
	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 src="Images/flash01.swf" wmode="opaque" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'" menu="false" bgcolor="#F0F0F0" 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>
</body>

</html>


这个是我替换后的代码
<SCRIPT type=text/javascript>
	<!--
	
	var focus_width=145	
	var focus_height=130
	var text_height=20
	var swf_height = focus_height+text_height
	
	var pics='<% 
			 set rs=server.createobject("adodb.recordset")
             rs.open "select top 5 * from news WHERE photonews='1'order by id desc",asconn
             do while not rs.eof 
            %><%=rs("newsimages")%>|<% rs.movenext 
               loop
               rs.close%>'
	var links='<% 
			 set rs=server.createobject("adodb.recordset")
             rs.open "select top 5 * from news WHERE photonews='1'order by id desc",asconn
             do while not rs.eof 
            %>show_news.asp?id=<%=rs("id")%>|<% rs.movenext 
               loop
               rs.close%>'
	var texts='<% set rs=server.createobject("adodb.recordset")
rs.open "select top 5 * from news WHERE photonews='1'order by id desc",asconn
             do while not rs.eof 
            %><%=cutstr(rs("title"),10)%>|<% rs.movenext 
               loop
               rs.close%>'
	
	document.write('<object 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/flash01.swf"><param name="quality" value="high"><param name="bgcolor" value="#F0F0F0">');
	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 src="Images/flash01.swf" wmode="opaque" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'" menu="false" bgcolor="#F0F0F0" 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>



asstudio

职务:普通成员
等级:1
金币:0.0
发贴:4
#22006/10/26 9:45:05
没有人帮忙了啊 ????