%dim m,ns_id,nt_title,ns_title,ns_content,ns_skim,ns_ntid
ns_id=trim(request("ns_id"))
if ns_id = "" then header("index.asp")
if not isnumeric(ns_id) then
response.Write("")
response.End()
end if
ns_ntid=conn.execute("select ns_ntid from Eas_News_List where ns_id = "&ns_id&"")(0)
sql = "select * from Eas_News_Type where nt_id = "&ns_ntid&""
set rs =ado_query(sql,conn)
if rs.recordcount = 0 then header("index.asp")
nt_title =rs("nt_title")
conn.execute("update Eas_News_List set ns_hit=ns_hit+1 where ns_id="&ns_id)
sql = "select * from Eas_News_List where ns_id ="&ns_id&" and ns_ntid ="&ns_ntid&""
set rs =ado_query(sql,conn)
if rs.recordcount = 0 then header("index.asp")
ns_title = rs("ns_title")
ns_content = rs("ns_content")
ns_skim = rs("ns_skim")
rs.close
set rs=nothing
%>
上一篇:
<%sql="select top 1 ns_id,ns_title from Eas_News_List where ns_ntid = "&ns_ntid&" and ns_id > "&ns_id&" order by ns_id asc"
set rs=ado_query(sql,conn)
if (rs.eof and rs.bof) then
echo "暂无信息"
else
echo ""&rs(1)&""
end if
rs.close
set rs=nothing
%>
下一篇:
<%sql="select top 1 ns_id,ns_title from Eas_News_List where ns_ntid = "&ns_ntid&" and ns_id < "&ns_id&" order by ns_id desc"
set rs=ado_query(sql,conn)
if (rs.eof and rs.bof) then
echo "暂无信息"
else
echo ">"&rs(1)&""
end if
rs.close
set rs=nothing
%>