[求助!]flash图片新闻--调用数据库出现问题
制作页面flash图片新闻循环显示:
数据库为tb_pic.mdb
表为tb_pic表:
NewID ID自动编号
picname 图片名称
picURL 图片地址
piclink 图片链接地址 下面代码执行是页面一片空白,是怎么回事?谢谢!
----------------------------------------------------------------
<!--#include file= "conn.asp "-- >
<%
set rs=server.CreateObject( "ADODB.RecordSet ")
sql= "select * from tb_pic "
rs.Open sql,conn,1,1 dim imgUrl(5)
dim imgtext(5)
dim imgLink(5) dim y
y=1 do while not rs.eof and y <=5 imgUrl(y)= "uploadfile/ " & rs( "picname ")
imgtext(y)= "uploadfile/ " & rs( "title ")
imgLink(y)= "index.asp " rs.movenext
y=y+1
loop
% > <script language= "javascript " type= "text/javascript " >
<!--
var focus_width=240;
var focus_height=180;
var text_height=21;
var swf_height = focus_height+text_height var pics=imgUrl(1)+ " ¦ "+imgUrl(2)+ " ¦ "+imgUrl(3)+ " ¦ "+imgUrl(4)+ " ¦ "+imgUrl(5)
var links=imgLink(1)+ " ¦ "+imgLink(2)+ " ¦ "+imgLink(3)+ " ¦ "+imgLink(4)+ " ¦ "+imgLink(5)
var texts=imgtext(1)+ " ¦ "+imgtext(2)+ " ¦ "+imgtext(3)+ " ¦ "+imgtext(4)+ " ¦ "+imgtext(5) 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= "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 src= "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= " '+ focus_height + ' " allowScriptAccess= "sameDomain " type= "application/x-shockwave-flash " pluginspage= "http://www.macromedia.com/go/getflashplayer " / > ');
document.write( ' </object > ');
//-- >
</script >
<%
rs.close
set rs=nothing
% >===================================
请求帮忙!!!谢谢!!!
制作页面flash图片新闻循环显示:
数据库为tb_pic.mdb
表为tb_pic表:
NewID ID自动编号
picname 图片名称
picURL 图片地址
piclink 图片链接地址 下面代码执行是页面一片空白,是怎么回事?谢谢!
----------------------------------------------------------------
<!--#include file= "conn.asp "-- >
<%
set rs=server.CreateObject( "ADODB.RecordSet ")
sql= "select * from tb_pic "
rs.Open sql,conn,1,1 dim imgUrl(5)
dim imgtext(5)
dim imgLink(5) dim y
y=1 do while not rs.eof and y <=5 imgUrl(y)= "uploadfile/ " & rs( "picname ")
imgtext(y)= "uploadfile/ " & rs( "title ")
imgLink(y)= "index.asp " rs.movenext
y=y+1
loop
% > <script language= "javascript " type= "text/javascript " >
<!--
var focus_width=240;
var focus_height=180;
var text_height=21;
var swf_height = focus_height+text_height var pics=imgUrl(1)+ " ¦ "+imgUrl(2)+ " ¦ "+imgUrl(3)+ " ¦ "+imgUrl(4)+ " ¦ "+imgUrl(5)
var links=imgLink(1)+ " ¦ "+imgLink(2)+ " ¦ "+imgLink(3)+ " ¦ "+imgLink(4)+ " ¦ "+imgLink(5)
var texts=imgtext(1)+ " ¦ "+imgtext(2)+ " ¦ "+imgtext(3)+ " ¦ "+imgtext(4)+ " ¦ "+imgtext(5) 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= "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 src= "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= " '+ focus_height + ' " allowScriptAccess= "sameDomain " type= "application/x-shockwave-flash " pluginspage= "http://www.macromedia.com/go/getflashplayer " / > ');
document.write( ' </object > ');
//-- >
</script >
<%
rs.close
set rs=nothing
% >===================================
请求帮忙!!!谢谢!!!
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货