asp实现的可以提示生日的几种方法附代码
发布时间:2023-11-23 10:17:47 所属栏目:Asp教程 来源:
导读:asp生日自动提醒小程式 用ASP编写,调试通过,使用方便-asp birthday automatically remind small programs with the preparation of ASP, debug, easy to use
最初写的一个用于班级网站的最近一个月同学生日的提
最初写的一个用于班级网站的最近一个月同学生日的提
|
asp生日自动提醒小程式 用ASP编写,调试通过,使用方便-asp birthday automatically remind small programs with the preparation of ASP, debug, easy to use 最初写的一个用于班级网站的最近一个月同学生日的提醒小程序。虽然不怎么样,而且很乱,但是最起码是自己动脑筋去想的,所以我比较看重。ASP程序虽然有好多可以借鉴人家的。但是我想更多时候,我们应该在经典上有所突出,有所创新那不至于默守陈规而无永远只能做一个平凡的程序员。 <% dim daydif dim days '定义查询前后多少天内生日的同学,如60则查询前一个月后下一个月生日的同学名单。 SQL="Select name,brithday from class " Set rs=server.CreateObject("ADODB.RecordSet") rs.Open SQL,con,1,1 for i=1 to rs.recordcount '读出所有的数据 if rs.eof then exit for daydif=abs(datediff("d",date,rs("birthday")) )mod 365 if daydif < days response.write rs("name")%> response.write "<font color="#FF0000">" response.write rs("birthday")&"、</font>" end if rs.movenext loop rs.Close Set rs=nothing (编辑:汽车网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
推荐文章
站长推荐
