<%
dim conn,rs,sql,connstr,dbpath,zsql,thetitle
connstr="DefaultDir=;driver={Microsoft Access Driver (*.mdb)};"
dbpath="dbq="&server.mappath("./vip/jiajie.mdb")
set conn=server.createobject("ADODB.CONNECTION")
conn.open connstr&dbpath
thetitle="欢迎光临慈溪市兴盛轴承有限公司"
set sql=server.createobject("adodb.recordset")
set rs=server.createobject("adodb.recordset")
session("denglu")=""%>
<%'------------------------------------管理员登陆-----------------------------
if trim(request("userid"))<>"" and trim(request("password"))<>"" then
set sql=server.createobject("adodb.recordset")
sql.open"select * from huiyuan",conn,1,1
do while not sql.eof
if trim(sql("userid"))=trim(request("userid")) and trim(sql("password"))=trim(request("password")) then
session("denglu")=sql("id")
response.redirect"product.asp"
exit do
end if
sql.movenext
loop
sql.close
end if
sub ShowProductClass
classtree="
"
sql.open"select * from lb",conn,1,1
do while not sql.eof
thestyle="style=display:none"
if len(request("zlbh"))>1 then
if trim(sql("lbh"))=mid(trim(request("zlbh")),1,instr(trim(request("zlbh")),".")-1) then
thestyle="style=display:block"
end if
end if
if sql("top")=False then
lbimg="line_01.gif"
lblink="href='#' onclick='jim(ttt"&sql("lbh")&");return false'"
else
lbimg="line_02.gif"
lblink="href=product.asp?dlbh="&sql("lbh")
end if
classtree=classtree & "