asp在新闻后加new图标的问题! 30
加新闻的代码已经有了,在下面这个代码中哪个位置加最好<%subnews_list(n_num,c_num)dimnsid,nsname,srs,ssql,sqla,n_u...
加新闻的代码已经有了,在下面这个代码中哪个位置加最好
<%
sub news_list(n_num,c_num)
dim nsid,nsname,srs,ssql,sqla,n_username,n_topic,n_tim,sid_num
sid_num=0
ssql="select s_id,s_name from jk_sort where c_id="&cid&" order by s_order"
set srs=joekoe_cms.exec(ssql,1)
do while not srs.eof
sid_num=1
nsid=srs("s_id")
nsname=srs("s_name")
sqla=" and s_id="&nsid
response.write vbcrlf&news_bar_top(nsname,1,1,"?action=more&c_id="&cid&"&s_id="&nsid)
sql="select top "&n_num&" id,topic,tim,username,counter,ispic from news where hidden=1 and s_id="&nsid&" order by id desc"
set rs=joekoe_cms.exec(sql,1)
do while not rs.eof
sid_num=2
n_username=rs("username")
n_topic=rs("topic")
n_tim=rs("tim")
n_tim=joekoe_cms.time_type(n_tim,1)
response.write vbcrlf&news_topic_type(c_num,rs("id"),n_username,n_topic,n_tim,rs("counter"),rs("ispic"),2)
rs.movenext
loop
rs.close
response.write vbcrlf&news_bar_end("",1)
srs.movenext
loop
srs.close
set srs=nothing
end sub
%> 展开
<%
sub news_list(n_num,c_num)
dim nsid,nsname,srs,ssql,sqla,n_username,n_topic,n_tim,sid_num
sid_num=0
ssql="select s_id,s_name from jk_sort where c_id="&cid&" order by s_order"
set srs=joekoe_cms.exec(ssql,1)
do while not srs.eof
sid_num=1
nsid=srs("s_id")
nsname=srs("s_name")
sqla=" and s_id="&nsid
response.write vbcrlf&news_bar_top(nsname,1,1,"?action=more&c_id="&cid&"&s_id="&nsid)
sql="select top "&n_num&" id,topic,tim,username,counter,ispic from news where hidden=1 and s_id="&nsid&" order by id desc"
set rs=joekoe_cms.exec(sql,1)
do while not rs.eof
sid_num=2
n_username=rs("username")
n_topic=rs("topic")
n_tim=rs("tim")
n_tim=joekoe_cms.time_type(n_tim,1)
response.write vbcrlf&news_topic_type(c_num,rs("id"),n_username,n_topic,n_tim,rs("counter"),rs("ispic"),2)
rs.movenext
loop
rs.close
response.write vbcrlf&news_bar_end("",1)
srs.movenext
loop
srs.close
set srs=nothing
end sub
%> 展开
2个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询