根据日期显示圣诞节图像

show christmas images based on date

我希望能够根据日期(例如 12 月 15 日和 12 月 28 日)打开和关闭代码,以便显示我的图像,然后消失。目前我正在这样做:

<% If 1=2 Then %>
<p><!--#include file="include_files/holiday-include-Christmas.htm"--></p>
<% End If %>

我必须将 1=2 更改为 1=1。我想让它自动完成。

只需检查日期:

<%
today   = Date
mindate = DateSerial(Year(today), 12, 15)
maxdate = DateSerial(Year(today), 12, 28)
If today >= mindate And today <= maxdate Then
%>