新微赢技术网

标题: response.write超连接问题 [打印本页]

作者: 绝爱吗?    时间: 2010-1-7 23:49
标题: response.write超连接问题
<script type="text/JavaScript">
<!--
function MM_jumpMenu(targ,selObj,restore){ //v3.0
eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
if (restore) selObj.selectedIndex=0;
}
//-->
</script>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><form name="form1">
<div align="right">

<select name="menu1" onChange="MM_jumpMenu('blank',this,0)">

<option value="1">--Web fink--</option>
<option value="2">
<% '从news表中读取友情连接
Set Rs1 = Server.CreateObject("ADODB.RecordSet")
Sql1="Select * From news where nfrom='英文' and typeid=66"
Rs1.Open Sql1,conn,1,1
Do While not Rs1.EOF
Response.Write "<option ><a href="& trim(rs1("link")) &">"& rs1("Title") &"</a></option>"
Rs1.MoveNext
Loop
Rs1.Close
Set Rs1=nothing
%>
</option>

</select>
</div>
</form></td>
</tr>
</table>
在做友情连接的时候,怎么连接不上数据库里数据
作者: lianeh    时间: 2010-1-7 23:49
<% Do While not Rs1.EOF %>
<option ><a href="<%=rs1("link")%>">rs1("Title")</a></option>
<%Rs1.MoveNext
Loop
Rs1.Close
Set Rs1=nothing
%>
作者: 青苹果    时间: 2010-1-7 23:49
<% Do While not Rs1.EOF %>
<option ><a href="<%=rs1("link")%>"><%=rs1("Title")%></a></option>
<%Rs1.MoveNext
Loop
Rs1.Close
Set Rs1=nothing
%>




欢迎光临 新微赢技术网 (http://bbs.weiying.cn/) Powered by Discuz! X3.2