谁帮我写一个程序.关于ASP的时间程序

来源:百度知道 编辑:UC知道 时间:2024/05/08 20:36:36
我做了一个网站.不知道怎么把更新的最后时间变成红色,请高手帮我写这个代码.让我的那个最后的更新时间变成红色.谢谢
晕.你当我是笨蛋啊......
我是说最后一天更新的要显红色.其他的不显啊
?<%
t=0
Set rs=Server.CreateObject("ADODB.RecordSet")
sql="SELECT * from NEWS where BigClassName='最近更新' order by id desc"
rs.Open sql,conn,1,1
if not Rs.eof then
do while not rs.eof
t=t+1
%>
<table width="255" border="0">
<tr>
<td width="179"><span class="STYLE27"><a href="../news/<%=rs("id")%>.html"target=_blank>[<%=rs("BigClassName")%>]<%=left(rs("title"),10)%></a></td>
<td width="66"><%=rs("infotime")%></td>
</tr>
</table>
<%
if t>=10 then exit do
rs.movenext
loop
else
response.write "<tr><

由于没看到源码,我给你说说思路吧。先从数据库中提取最后更新时间的日期,然后判断是和这个日期相符的,就让它红色显示

<red></red>
难道这个标签没有用么……囧
___________
按更新时间逆序,第一条显红色,即是条件t=1的时候
——————
难道把问题说得稍微具体一点不行么……