| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 699 人关注过本帖
标题:一道难到十年程序员的考题,这个首页文件为什么刚开始可以打开,过一段时间后 ...
只看楼主 加入收藏
fketcadw
Rank: 1
等 级:新手上路
帖 子:1
专家分:0
注 册:2006-9-17
收藏
 问题点数:0 回复次数:1 
一道难到十年程序员的考题,这个首页文件为什么刚开始可以打开,过一段时间后就打不开

<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
<%response.buffer=true%>
<%Response.ContentType = "text/vnd.wap.wml; charset=utf-8"%>
<!--#include file="conn.asp"-->
<!--#include file="noandad.asp"-->
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org/DTD/wml_1.1.xml">
<wml>
<head>
<meta http-equiv="Cache-Control" content="no-Cache"/>
<meta http-equiv="Cache-Control" content="max-age=0"/>
</head>

<card title="手机网址之家">
<%
if pno<>"" then
agent=request.serverVariables("HTTP_USER_AGENT")

set rsa=Server.CreateObject("ADODB.Recordset")
Sqll="select * from [user] where [num]='" & pno & "' order by ID desc"
rsa.open Sqll,conn,1,2

if rsa.recordcount=0 then
rsa.addnew
rsa("hit")=0
rsa("num")=pno
rsa("agent")=agent
rsa.update
response.redirect "index.asp"
end if

if rsa.recordcount>0 and rsa("hit")=1 then
rsa("hit")=rsa("hit")+1
rsa.update
response.redirect "main.asp"
end if

if rsa.recordcount>0 and rsa("hit")=0 then
rsa("hit")=rsa("hit")+1
rsa.update
end if

rsa.Close
set rsa=nothing
end if
%>

<p align="center"><img src='img/logo.gif' alt=''/></p><p>
<%
set rst=server.createobject("ADODB.Recordset")
Sql="select * from class where show=1 order by ClassID asc"
rst.open Sql,conn,1,2
%>

<%if rsn.recordcount > 0 then
rsn.movefirst
if len(rsn("time"))=8 then
l=3
elseif len(rsn("time"))=9 then
l=4
else
l=5
end if
%>
<a href="notice/view.asp?ID=<%=rsn("ID")%>"><%=ubb(rsn("title"))%></a>(<%=right(rsn("time"),l)%>)<br/>
<%end if%>
<%
if rsad.recordcount > 0 then
ad=1
do while not rsad.eof
%>
<a href="<%=rsad("adurl")%>"><%=ubb(rsad("adtitle"))%></a><br/>
<%
ad=ad+1
rsad.movenext
loop
end if
%>
<a href="http://wap.ypyl.net">一品娱乐门户</a><br/>
<a href="bookmark/index.asp">我的收藏夹</a>|<a href="search.asp">搜索</a>|<a href="ADD.asp">自助申请</a><br/>
<img src='img/rmwz.gif' alt='网址推荐'/><br/>
<%
if rst.recordcount = 0 then response.write("暂无网站!<br/>")
if rst.recordcount > 0 then
i=1
do while not rst.eof
%>
[<a href="list.asp?ids=<%=rst("ClassId")%>"><%=rst("ClassName")%></a>]
<%
set rstc=server.createobject("ADODB.Recordset")
rstcstr="select * from urls where check=1 and show=1 and classid="& rst("ClassId") &" order by showorder asc"
rstc.open rstcstr,conn,1,2
j=1
do while not rstc.eof
%>
<a href='view.asp?ids=<%=rstc("classid")%>&amp;wid=<%=rstc("wid")%>'><%=rstc("site")%></a>&nbsp;
<%
j=j+1
rstc.movenext
loop
rstc.Close
set rstc=nothing
%>
<br/><%i=i+1
rst.movenext
loop
rst.Close
set rst=nothing
%>
<%end if%>
<img src='img/flwz.gif' alt='网址大全'/><br/>
<%
set rsto=server.createobject("ADODB.Recordset")
rstostr="select * from class order by ClassID asc"
rsto.open rstostr,conn,1,2

o=1
do while not rsto.eof
%>
<a href="list.asp?ids=<%=rsto("ClassId")%>"><%=rsto("ClassName")%></a>
<%
if o Mod 3=0 or o=rsto.recordcount then
response.Write "<br/>"
else
response.Write "|"
end if
o=o+1
rsto.movenext
loop
rsto.Close
set rsto=nothing
%>
<img src='img/line.gif' alt='----------'/><br/>
<a href="gbook/index.asp">留言</a>|<a href="help.asp">帮助</a><br/>
<!--#include file="admin.asp"-->
<a href="manage.asp">管理</a>|
<% end if %>
<a href="help/4.asp">存为书签</a><br/>

QQ:
</p>
</card>
</wml>

搜索更多相关主题的帖子: 考题 程序员 首页 文件 时间 
2006-09-17 21:58
hu9jj
Rank: 20Rank: 20Rank: 20Rank: 20Rank: 20
来 自:红土地
等 级:贵宾
威 望:400
帖 子:11786
专家分:43421
注 册:2006-5-13
收藏
得分:0 
你这样粘贴上来恐怕没有谁能看的清楚.

活到老,学到老!http://www.(该域名已经被ISP盗卖了)E-mail:hu-jj@
2006-09-17 22:11
快速回复:一道难到十年程序员的考题,这个首页文件为什么刚开始可以打开,过一段时 ...
数据加载中...
 
   



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

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