黄巾起义死了多少人:假如想用fenlei.asp?id=1来跳转到index1.asp?
来源:百度文库 编辑:神马品牌网 时间:2024/04/29 18:14:39
假如想用fenlei.asp?id=1来跳转到index1.asp
fenlei.asp到代码该怎么写
以下代码不知道错在哪里。
<%
Dim id
id = Request("id")
%>
<%
name="&id&"
if(name="1") then
response.redirect ("index1.asp")
if(name="2") then
response.redirect ("index2.asp")
if(name="3") then
response.redirect ("index3.asp")
elseif(name="4") then
response.redirect ("index4.asp")
end if
%>
跳转到代码是网上找的,我也不知道最后为什么最后4用elseif.
fenlei.asp到代码该怎么写
以下代码不知道错在哪里。
<%
Dim id
id = Request("id")
%>
<%
name="&id&"
if(name="1") then
response.redirect ("index1.asp")
if(name="2") then
response.redirect ("index2.asp")
if(name="3") then
response.redirect ("index3.asp")
elseif(name="4") then
response.redirect ("index4.asp")
end if
%>
跳转到代码是网上找的,我也不知道最后为什么最后4用elseif.
<%
Dim id
dim str
id = Request("id")
str="index" & id & ".asp"
response.redirect str
%>
首先,我是门外汉..
我看
是不是if和elseif的问题啊???
为什么最后4你用elseif..其它都不用呢?
你的错在这句上,name="&id&"
你的意思,肯定是将网页地址中id这个参数的值赋给name变量。即然你上面有了id = Request("id"),那就应该是name=id即可!
或者你采用我楼上写的这种方法更好一些。
你找的这个,很适合学习,却很不符合逻辑,因为太罗嗦了,一点不简洁!
假如想用fenlei.asp?id=1来跳转到index1.asp?
如何隐藏下载绝对路径,假如用xx.asp?id=1
standinfo.asp?id=1是什么意思
用这个连接:<href="show.asp?id=615">或<href="show.php?id=615">来打开一个文件或页面。是怎么做的?
asp查询语句where id=1 or id=2 or id=3...有很多的or会影响效率吗?
请高手急救我的show.asp打开每个网页都是http://......./show.asp?id=1
http://www.haopp.com/play.asp?id=1417&no=1
http://bbs.xyidc.net/dispbbs.asp?boardid=21&id=308&page=1想大家帮忙告诉我背景音乐是什么,
谁知道ASP?id=54554这种是怎样连接的
index.asp?id=%BC%D7%BF%C7%B3%E6AC