As Ian pointed out you can generate a UTC time via Javascript.
You specified "ASP Classic" which of course includes Javascript as a language, so there's one answer for you: Call (new Date()).toUTCString()
.
If by chance you prefer to code your pages in mostly VBScript, you can mix in just a little Javascript to get it done. You don't need to resort to Server.Execute
or Sessions to make that happen.
This works for me:
<%@ language="VBScript" %>
<script language='Javascript' runat='server'>
function jsGetUTCTime() {
var d = new Date();
return d.toUTCString();
}
</script>
<script language='VBScript' runat='server'>
Function getUTCTime()
' Use JScript to get the current GMT time stamp
getUTCTime = jsGetUTCTime()
End Function
</script>
<!DOCTYPE html>
<html>
<head>
<title>Mix</title>
</head>
<body>
<h2>The time is:</h2>
<%= getUTCTime() %>
</body>
</html>
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…