asp+js问题
程序代码:
<% Call openDataBase() set gsxw = Server.CreateObject("Adodb.recordset") gsxw.open "SELECT top 5 * FROM Sbe_News WHERE TID<>8 and datepart('yyyy',newsdate)=datepart('yyyy',now()) and PhotoNew = -1 order by newsdate desc ",conn,1,1 %> <script language="JavaScript" type="text/javascript"> var arra=new Array(); <%for i=1 to gsxw.recordcount%> arra[<%=i-1%>] = <%=gsxw("pic")%> <%next%> var i=0; for(i=0;i<arra.length;i++) alert(arra[i]); </script>
出现问题 弹不出