当前位置: 代码迷 >> ASP >> asp怎样实现地址栏中输入123.asp?s_type=1显示网页内容?该如何处理
  详细解决方案

asp怎样实现地址栏中输入123.asp?s_type=1显示网页内容?该如何处理

热度:99   发布时间:2012-03-14 12:01:12.0
asp怎样实现地址栏中输入123.asp?s_type=1显示网页内容?
asp怎样实现地址栏中输入123.asp?s_type=1显示网页内容?

set   rs=server.createobject( "adodb.recordset ")
sql= "select   *   from   study   where   s_type= "&cstr(request.querystring( "s_type "))& "   order   by   s_id   desc "

?s_type=电脑知识

为什么不会显示??

------解决方案--------------------
where s_type= "&cstr(request.querystring( "s_type "))& "

改为

where s_type= ' "&cstr(request.querystring( "s_type "))& " '

要加 ' ' 的