Hello
I have tried some code to try and get the current date to appear as in 1st June 1999, 2nd July 1998, 3rd August 2001, 4th September 1987, but I am having difficulty with it.
This is what I have:
<HTML>
<HEAD>
<TITLE></TITLE>
</HEAD>
<BODY BGCOLOR=WHITE>
<FONT FACE=VERDANA COLOR=BLUE SIZE=5>
<LANGUAGE="VBScript">
Response.Write WriteDate()
Function Suffix(number)
SELECT CASE Number
CASE 1
temp = "st"
CASE 2
temp = "nd"
case 3
temp = "rd"
CASE ELSE
temp = "th"
END SELECT
Suffix = number & temp
End Function
Function WriteDate(theDate)
WriteDate = Suffix(Day(theDate)) & " " & Monthname(Month(theDate)) & " " & Year(theDate)
End Function
</SCRIPT>
</FONT>
</BODY>
</HTML>
I am unsure about what should be inserted - if anything - in the brackets here:
Response.Write WriteDate(<your date>)
and I probably need to insert (somewhere!) some kind of statement along the following lines:
<%Session.LCID = 2057%>
to force UK time values. Should this be inerted at the very top of the page, or doesn't it matter?
Please let me know what I'm doing wrong.
Best wishes
I have tried some code to try and get the current date to appear as in 1st June 1999, 2nd July 1998, 3rd August 2001, 4th September 1987, but I am having difficulty with it.
This is what I have:
<HTML>
<HEAD>
<TITLE></TITLE>
</HEAD>
<BODY BGCOLOR=WHITE>
<FONT FACE=VERDANA COLOR=BLUE SIZE=5>
<LANGUAGE="VBScript">
Response.Write WriteDate()
Function Suffix(number)
SELECT CASE Number
CASE 1
temp = "st"
CASE 2
temp = "nd"
case 3
temp = "rd"
CASE ELSE
temp = "th"
END SELECT
Suffix = number & temp
End Function
Function WriteDate(theDate)
WriteDate = Suffix(Day(theDate)) & " " & Monthname(Month(theDate)) & " " & Year(theDate)
End Function
</SCRIPT>
</FONT>
</BODY>
</HTML>
I am unsure about what should be inserted - if anything - in the brackets here:
Response.Write WriteDate(<your date>)
and I probably need to insert (somewhere!) some kind of statement along the following lines:
<%Session.LCID = 2057%>
to force UK time values. Should this be inerted at the very top of the page, or doesn't it matter?
Please let me know what I'm doing wrong.
Best wishes