Home > Web Front-end > HTML Tutorial > How to determine whether the uploaded menu to the second-level page is the first-level menu or the second-level menu? _html/css_WEB-ITnose

How to determine whether the uploaded menu to the second-level page is the first-level menu or the second-level menu? _html/css_WEB-ITnose

WBOY
Release: 2016-06-24 12:11:10
Original
1332 people have browsed it



<%
typeid=cint(request.querystring("E_typeid"))
bigclassid=cint(request.QueryString("e_bigclassid"))
smallclassid=cint(request.QueryString("e_smallclassid"))
pages=cint(request.QueryString("pages"))
if pages=0 or isnull(pages) then pages=1
if typeid=0 then typeid=99999
if bigclassid=0 then bigclassid=99999
if smallclassid=0 then smallclassid=99999
if typeid<>""  or typeid<>0 then str="E_typeid="&typeid
if bigclassid<>""  or bigclassid<>0 then str=str&"&e_bigclassid="&bigclassid
if smallclassid=0 then  str=str else str=str&"&smallclassid="&smallclassid

sql1="select E_bigclassname from EC_BigClass where  E_BigClassID="&bigclassid
sql2="select E_smallClassName from ec_smallclass where E_smallClassID="&smallclassid
' response.write typeid&smallclassid&bigclassid
set rs1=server.createobject("adodb.recordset")
rs1.open sql1,conn,1,3
bigclassname=rs1("E_bigclassname")
rs1.close
rs1.open sql2,conn,1,3
smallclassname=rs1("E_smallclassname")
rs1.close
if smallclassid<>0 then smallclassname=rs1("E_smallclassname")
rs1.close
'response.write bigclassname &smallclassname&sql1&sql2

%>


Index2











这样只能显示二级菜单中的内容,我想实现点一级菜单时显示<%=bigclassname%>的内容,点二级时显示<%=smallclassname%>
求高手指点!


回复讨论(解决方案)

一级菜单和2级菜单 传递不同的参数
以此来判断。

一级菜单和2级菜单 传递不同的参数
以此来判断。

是直接在

里面判断吗?怎么判断?

就写
if bigclassid <> "" then
  一级菜单的代码
else
  2级菜单对应的代码
end if



是这样写吗?可是有错误啊



Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
  <%=smallclassname%>

E_SmallClassID=<%=smallclassid%>&shu=17&title=100&time=1&click=1" 

charset="gb2312">
 <%=smallclassname%>  

if bigclassid <> "" then
  <% =smallclassname%>
   
else
 <%=bigclassname%>
  
<%
if bigclassid <> "" then
  response.write bigclassname
else
  response.write smallclassname
end if
%>