Friday, January 28, 2011

Getting the current page URI in classic ASP

This JScript gets the current URI in a classic ASP server page:

function getSv(name) { return Request.ServerVariables(name) }
var currentUri = ((getSv("HTTPS") == "off") ? "http" : "https") + "://" + getSv("SERVER_NAME") + getSv("SCRIPT_NAME")

0 comments:

Post a Comment