Tips and tricks for .NET using ASP and VB code.

Add date and time (in internet standard format) to the bottom of every web page

In the Global.asax file, add this code:
    Protected Sub Application_PostRequestHandlerExecute(ByVal sender As Object, ByVal e As System.EventArgs)
Response.Write(Replace("<BR clear='all'>", "'", ControlChars.Quote) & Now.ToUniversalTime.ToString("ddd, dd MMM yyyy HH:mm:ss 'GMT'"))
End Sub

No comments:

Post a Comment

Search This Blog