The principle is relatively simple, that is, using the date function to obtain the date, and then replacing it with a fixed string array.
Copy the code as follows:td=date()
'This time we set the current date, mainly for the convenience of debugging. In actual applications, you can use the current day's date..
str=123456
' Generate a string with specific day of the week , just take it based on the position..
for x=1 to 7
'This loop is mainly to determine which day is the nearest Monday...
if td-weekday(td)+1+x=td then
'This judgment is to make the current date appear in red, it has no special value..
response.write <font color=red>week&mid(str,x,1)&:&FormatDateTime(td-weekday(td)+1+x, 1)&</font><br>
else
response.write week&mid(str,x,1)&:&FormatDateTime(td-weekday(td)+1+x,1)&<br>
end if
next