标题:各位好心的高手来帮小弟一下吧
只看楼主
huye1985
Rank: 1
等 级:新手上路
帖 子:54
专家分:0
注 册:2008-3-3
 问题点数:0 回复次数:4 
各位好心的高手来帮小弟一下吧
这段代码中最后的call down 中的down函数在哪个地方或是从哪个文件中调用的

<!--#include file="up.asp"-->
<%
dim action,comeurl,mark,graden
action=request.querystring("action")
select case action
case""
comeurl=Request.ServerVariables("HTTP_REFERER")
%>
<%=ttop%>
<table align="center" border="1" bordercolor=<%=c2%> cellpadding="0" cellspacing="0" style="border-collapse: collapse;" width="<%=tbw%>">
  <tr>
    <td class=td1 width="100%" height="28" bgcolor="<%=c1%>" background="<%=tbg%>">?<img border="0" src="pic/gl.gif" width="19" height="15"> 用户登陆</td>
  </tr>
<form action=login.asp?action=login method="POST"><tr>
    <td width="100%">
    <table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" width="100%">
      <tr>
        <td width="35%" height="28"><b>?请输入您的用户名:</b></td>
        <td width="65%">?<input type=text name=lgname size='20'>? <a href=reg.asp>没有注册?</a></td>
      </tr>
      <tr>
        <td height="28"><b>?请输入您的密码:</b></td>
        <td>?<input type=password name=lgpwd size='20'></td>
      </tr>
      <tr>
        <td height="28"><b>?请输入登陆验证码:</b></td>
        <td>?<input type=text name=adminid size='20'>? <%response.write"<img src=code.asp>"%></td>
      </tr>
      <tr>
        <td height="40"><b>?Cookie 选项:</b><br>
        ?请选择您的 Cookie 保存时间</td>
        <td>?<select name=cook style="font-family: 宋体 (serif); font-size: 9pt">
        <option value=0>不保存</option><option value=1>保存一天</option>
        <option value=30>保存一月</option><option value=365>保存一年</option></select><input type="hidden" name="comeurl" size="20" value="<%=server.htmlencode(comeurl)%>"></td>
      </tr>
      <tr>
        <td height="40"><b>?登陆方式:</b><br>
        ?请选择您的登陆方式</td>
        <td><input type=radio value=1 checked name=lgtype>正常登陆?<input type=radio value=2 name=lgtype>隐身登陆</td>
      </tr>
      <tr>
        <td height="30" colspan="2" align="center" bgcolor="<%=c2%>"> <input type='submit' value='   登    陆   ' name='B1' class=submit>?
        <input type='reset' value='   重    置   ' name='B2' class=submit></td>
      </tr>
    </table>
    </td>
  </tr></form>
</table>
<%=tbottom%>

<%case"login"
dim adminid,cook,login
lgname=Replace(Request.Form("lgname"),"'","''")
lgpwd=Replace(Request.Form("lgpwd"),"'","''")
adminid=Replace(Request.Form("adminid"),"'","''")
comeurl=Replace(Request.Form("comeurl"),"'","''")
lgtype=checknum(Request.Form("lgtype"))
cook=checknum(Request.Form("cook"))
%><!--#include file="inc/md5.asp"-->
<%
login=true
if session("adminid")<>adminid or not isnumeric(adminid) or adminid="" then
login=false
mes="·您输入的验证码错误,请输入正确的四位验证码!<br>"
else
function pname(str)
pname=true
if Instr(str,"=")>0  or Instr(str,"%")>0 or Instr(str,chr(32))>0  or Instr(str,"?")>0 or Instr(str,"&")>0 or Instr(str,";")>0 or Instr(str,",")>0  or Instr(str,"'")>0 or Instr(str,".")>0 or Instr(str,chr(34))>0 or Instr(str,chr(9))>0  or Instr(str,"?")>0 or Instr(str,"$")>0 or Instr(str,chr(255))>0 or Instr(str,":") or instr(str,"|")>0  or instr(str,"#")>0 or instr(str,"`")>0 or instr(str,"\")>0 or instr(str,"(")>0 or instr(str,"[")>0 or instr(str,"-")>0 or instr(str,"~") then
pname=false
end if
end function

if pname(lgname)=false then
login=false
mes=mes&"·您的用户名或者密码错误,或者该用户已经被删除。<br>"
else
lgpwd=md5(lgpwd)
set rs=conn.execute("select top 1 userid,mark,grade,type from [user] where name='"&lgname&"' and password='"&lgpwd&"' and not del")
if rs.eof then
login=false
mes=mes&"·您的用户名或者密码错误,或者该用户已经被删除。<br>"
else
login=true
lguserid=rs("userid")
session(prefix&"usertype2")=rs("type")
mark=rs("mark")+1
graden=mark\200
grade=rs("grade")
end if
set rs=nothing
end if
end if


if login=false then
tl=" 登 陆 失 败"
response.write"<img src=code.asp style='display:none' width=0 height=0>"
mes=mes&"·<a href='javascript:history.go(-1)'><img border=0 src=pic/re.gif align=absmiddle>返回重新填写</a>"
else
Response.Cookies(prefix)("lgname")=lgname
session(prefix&"lgname")=lgname
Response.Cookies(prefix)("lgpwd")=lgpwd
Response.Cookies(prefix)("lgtype")=lgtype
Response.Cookies(prefix)("lgcook")=cook
if cook>0 then
Response.Cookies(prefix).Expires=date+cook
end if
session(prefix&"lguserid")=lguserid
lguserid=session(prefix&"lguserid")
conn.execute("update [user] set mark=mark+1,lasttime=now()+"&timeset&"/24 where userid="&lguserid&"")


'usertype 0游客 1会员 2vip 3版主 4超级 5管理员


adminbd="0"
usertype=1
if grade=13 then usertype=2

if grade=14 then
usertype=3
set getadminbd=conn.execute("select bd from admin where name='"&lgname&"' and password='"&lgpwd&"'")
do while not getadminbd.eof
adminbd=adminbd&"|"&getadminbd("bd")&"|"
getadminbd.movenext
loop
set getadminbd=nothing
end if

if grade=15 then usertype=4
if grade=16 then usertype=5

if usertype<2 then
if graden>13 then graden=13
conn.execute("update [user] set grade="&graden&" where userid="&lguserid&"")
end if

session(prefix&"usertype")=usertype
session(prefix&"adminbd")=adminbd

dim sql
conn.execute("delete*from online where ip='"&ip&"' or userid="&lguserid&"")
if lgtype=1 then
sql="insert into online values("&lguserid&",'"&lgname&"','"&ip&"',now(),"&usertype&",true,0,'')"
else
sql="insert into online values("&lguserid&",'"&lgname&"','"&ip&"',now(),"&usertype&",false,0,'')"
end if

conn.execute(sql)

if instr(comeurl,"reg.asp")>0 or instr(comeurl,"login.asp")>0 or comeurl="" then
comeurl=""
else
comeurl="·<br>·<a href="&comeurl&">"&server.htmlencode(comeurl)&"</a>"
end if
tl=" 登 陆 成 功"
mes="·<span id=sdown></span> 秒钟后将自动返回首页<br>·<a href='index.asp'>进入论坛首页</a>"&comeurl
%><%
end if
call sendinfo(tl,mes)
if login=true then%><script>
function countDown(secs){
sdown.innerText=secs;
if(--secs>0)
 setTimeout("countDown("+secs+")",1000);
  }
countDown(3);
</script><meta http-equiv=refresh content=2;url=index.asp><%end if
case"exit"
Response.Cookies(prefix)("lgname")=""
Response.Cookies(prefix)("lgpwd")=""
Response.Cookies(prefix)("lgtype")=""
Response.Cookies(prefix)("lgcook")=""
if isnull(lguserid) or lguserid="" then lguserid=0
conn.execute("delete*from [online] where userid="&lguserid&"")
session(prefix&"lgname")=""
session(prefix&"lguserid")=""
session(prefix&"usertype")=""
session(prefix&"adminbd")=""
session(prefix&"usertype2")=""
tl=" 退 出 成 功"
mes="·已经成功的退出论坛<br>·<a href=login.asp>重新登陆论坛</a><br>·<a href=index.asp>进入论坛首页</a><br>"
call sendinfo(tl,mes)
%><%
end select
call down%>
这段代码中最后的call down 中的down函数在哪个地方或是从哪个文件中调用的

[[it] 本帖最后由 huye1985 于 2008-3-4 15:26 编辑 [/it]]
搜索更多相关主题的帖子: 好心 action 
2008-03-04 15:25
永夜的极光
Rank: 6Rank: 6
等 级:贵宾
威 望:27
帖 子:2721
专家分:1
注 册:2007-10-9
得分:0 
<!--#include file="up.asp"-->
看看这个文件里面有没有

从BFS(Breadth First Study)到DFS(Depth First Study)
2008-03-04 15:55
huye1985
Rank: 1
等 级:新手上路
帖 子:54
专家分:0
注 册:2008-3-3
得分:0 
没有看到

我在这个网页里面找了没有找到
2008-03-04 16:56
huye1985
Rank: 1
等 级:新手上路
帖 子:54
专家分:0
注 册:2008-3-3
得分:0 
这个文件里面的代码如下 :
<!--#include file="inc.asp"-->
<%response.write"<link rel=stylesheet type=text/css href=inc/css.css>"
dim tinfo,binfo,ttop,tbottom,tbw,c1,c2,tbg
c1=request.cookies(prefix&"1")("c1")

if isnull(c1) or c1="" then
set rs=conn.execute("select*from style where autouse=true")
response.cookies(prefix&"1")("tinfo")=rs("tinfo")
response.cookies(prefix&"1")("binfo")=rs("binfo")
response.cookies(prefix&"1")("ttop")=rs("ttop")
response.cookies(prefix&"1")("tbottom")=rs("tbottom")
response.cookies(prefix&"1")("tbw")=rs("tbw")
response.cookies(prefix&"1")("c1")=rs("c1")
response.cookies(prefix&"1")("c2")=rs("c2")
response.cookies(prefix&"1")("tbg")=rs("tbg")
response.cookies(prefix&"1").Expires=date+365
set rs=nothing
end if
tinfo=request.cookies(prefix&"1")("tinfo")
binfo=request.cookies(prefix&"1")("binfo")
ttop=request.cookies(prefix&"1")("ttop")
tbottom=request.cookies(prefix&"1")("tbottom")
tbw=request.cookies(prefix&"1")("tbw")
c1=request.cookies(prefix&"1")("c1")
c2=request.cookies(prefix&"1")("c2")
tbg=request.cookies(prefix&"1")("tbg")
if isnull(c1) or c1="" then
response.write"对不起!您的 Internet Explorer 浏览器可能不支持 Cookies,不能使用本论坛。"
response.end
end if
%>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title><%=kbbs(bbsname)%></title>
<style type=text/css>
.td3{font-size:9px;face:Tahoma;color:#ffffff;font-weight: bold;BACKGROUND-COLOR:<%=c1%>}
.td4{BACKGROUND-COLOR:<%=c2%>}
.td5{BACKGROUND-COLOR:<%=c1%>;}</style>
<SCRIPT src=inc/menu.js></SCRIPT>
<%if style="" then
set rs=conn.execute("select id,stylename from style")
do while not rs.eof
style=style&"<a href=cookies.asp?action=style&styleid="&rs("id")&">"&rs("stylename")&"</a><br>"
rs.movenext
loop
set rs=nothing
application(prefix&"style")=style
end if
%><SCRIPT language=JavaScript>
var bbsstyle='<%=style%>'
var allthebbs='<%=allthebbs%>'
</SCRIPT>
<DIV id=menuDiv1 style='Z-INDEX: 2; VISIBILITY: hidden;POSITION: absolute;'></DIV>

<body topmargin=0>
<%response.write tinfo%>
<table align="center" border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" width="<%=tbw%>" height="28">
<tr><td width="100%" bgcolor="<%=c2%>">???
<%
dim lginfo
if isnull(lguserid) or lguserid="" then%><a href="login.asp">登 陆</a> ┆ <a href="reg.asp">注 册</a> ┆ <%else
if lgtype=1 then lginfo="隐 身"
if lgtype=2 then lginfo="上 线"
lginfo="<a href=cookies.asp?action=lgtype&cook="&lgcook&">"&lginfo&"</a> ┆ "
response.write lginfo
response.write"<a href=login.asp?action=exit>注 销</a> ┆ "
end if
%><a onmouseover=ShowMenu(bbsstyle)><SPAN style='CURSOR: hand'>论坛风格</span></a><%if lguserid<>"" then%> ┆ <a onmouseover=ShowMenu(userhelp)><SPAN style='CURSOR: hand'>会员功能</span></a> ┆ <a href=usersetup.asp onmouseover=ShowMenu(usersetup)>控制面板</a> ┆ <a href=bbsshow.asp>论坛展区</a><%end if%>
<%if usertype=5 then%> ┆ <a href=admin.asp>论坛管理</a><%end if%> ┆ <a href=help.asp>论坛帮助</a></td>
</tr>
</table><br>
<%
if lguserid<>"" then
dim newnum
newnum=conn.execute("select count(id) from sms where touserid="&lguserid&" and new=true")(0)
if newnum>0 then%>
<div id=tbtype0 style="position:absolute;  z-index:1; right:0; bottom: 0;display:''">
<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" width="280">
  <tr>
    <td width="100%" bgcolor="<%=c1%>" background="<%=tbg%>" height="28" colspan="2">
    <table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="98%">
      <tr>
        <td class=td1 width="50%">? <img src="pic/gl.gif" border="0"> 新留言</td>
        <td width="50%" align="right"><a onclick="showtb(0)"><SPAN style='CURSOR: hand'><img border="0" src="pic/close.gif"></span></a></td>
      </tr>
    </table>
    </td>
  </tr>
  <tr> <td valign="top">
    <img border="0" src="pic/mail.gif"></td>
    <td width="100%" bgcolor="<%=c2%>" valign="top">
    <p style="margin: 5; line-height:150%"><font color="<%=c1%>">您的留言板有 <b><%=newnum%></b> 条新留言,<br>请及时查收。</font></p>
<p style="margin: 5; line-height:150%"><a href="sms.asp"><img src="pic/newmail.gif" border="0" align="absmiddle"> <font color="<%=c1%>">查看留言板</font></a></p></td>
   
  </tr>
  </table>
</div><%end if
end if%>
<%dim urlinfo,url
url=Request("url")
sub bbsurl
if bd<>"" and isnumeric(bd) then
urlinfo=" → <a href='topiclist.asp?bd="&bd&"'>"&bdinfo(0)&"</a>"
if id<>"" and isnumeric(id) then
urlinfo=urlinfo&" → <a href=showbbs.asp?bd="&bd&"&id="&id&"&totable="&totable&">浏览当前帖子</a>"
end if
end if

if instr(url,"login.asp")>0 then urlinfo=urlinfo&" → 登陆 / 注销"
if instr(url,"reg.asp")>0 then urlinfo=urlinfo&" → 注册用户"
if instr(url,"userinfo.asp")>0 then urlinfo=urlinfo&" → 查看用户资料"
if instr(url,"addtopic.asp")>0 then urlinfo=urlinfo&" → 发表帖子"
if instr(url,"savetopic.asp")>0 then urlinfo=urlinfo&" → 保存帖子"
if instr(url,"usersetup.asp")>0 then urlinfo=urlinfo&" → <a href=usersetup.asp>控制面板</a>"
if instr(url,"sms.asp")>0 then urlinfo=urlinfo&" → <a href=sms.asp>我的留言板</a>"
if instr(url,"edit.asp")>0 then urlinfo=urlinfo&" → 编辑帖子"
if instr(url,"search.asp")>0 then urlinfo=urlinfo&" → <a href=search.asp>论坛搜索</a>"
if instr(url,"help.asp")>0 then urlinfo=urlinfo&" → <a href=help.asp>论坛帮助</a>"
if instr(url,"bbsshow.asp")>0 then urlinfo=urlinfo&" → <a href=bbsshow.asp>论坛展区</a>"

response.write"<table bgcolor="&c2&" align=center border=1 cellpadding=0 cellspacing=0 width="&tbw&" height=28 style='border-collapse: collapse'><tr><td width='100%'>??<img src=pic/fle.gif border=0> 您的位置: <a onmouseover=ShowMenu(allthebbs) href=index.asp>"&bbsname&"</a>"&urlinfo&"</td></tr></table><br>"
end sub
call bbsurl
time1=timer()
%>
2008-03-04 16:59
luoshouhe
Rank: 1
等 级:新手上路
帖 子:1
专家分:0
注 册:2011-10-2
得分:0 
response.cookies(prefix&"1")("tinfo")=rs("tinfo")
以及body 中 <%response.write tinfo%> 引用 tinfo,但是这个tinfo的内容我找遍了所有文件都没发现,数据库文件里面也没看到,从哪里修改呢
2011-10-02 16:34



参与讨论请移步原网站贴子:https://bbs.bccn.net/thread-201913-1-1.html




关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.329856 second(s), 7 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved