asp中最新新聞顯示new圖片的實(shí)現(xiàn)代碼
更新時(shí)間:2012年03月26日 17:21:29 作者:
很多朋友想在最新新聞顯示new圖片,以便訪客快速找到新更新的內(nèi)容,原理就是通過判斷日期
2天內(nèi)的現(xiàn)實(shí)new文字
<%if DateDiff("d",rs("date"),date())<2 then%><font color="#4FC5D9">NEW</font><%end if%>
七天之內(nèi)顯示new圖片
<%if Date()-rs("news_date")<7 then %> <img border="0" src="imges/new.gif" ><%end if%>
<%if DateDiff("d",rs("date"),date())<2 then%><font color="#4FC5D9">NEW</font><%end if%>
七天之內(nèi)顯示new圖片
<%if Date()-rs("news_date")<7 then %> <img border="0" src="imges/new.gif" ><%end if%>
相關(guān)文章
Ajax跨域代理訪問網(wǎng)絡(luò)資源的實(shí)現(xiàn)代碼
解決Ajax跨域訪問報(bào)“沒有權(quán)限”的錯(cuò)誤。需要的朋友可以參考下。2011-03-03ASP中實(shí)現(xiàn)限制IP的函數(shù)詳解
ASP中實(shí)現(xiàn)限制IP的函數(shù)詳解...2007-04-04asp下實(shí)現(xiàn)IP限制函數(shù)代碼
asp下實(shí)現(xiàn)IP限制函數(shù)代碼...2007-11-11