Last post Sep 16, 2020 09:38 PM by dlchase
Sep 16, 2020 08:56 PM|dlchase|LINK
How do I get the page name and/or url of the calling page in my internal web application? For example if my page is AuditTrail.aspx and the page that called it is OrgInfo.aspx I want to be able to know the page I came from. Thanks.
Sep 16, 2020 09:34 PM|mgebhard|LINK
The browser sets the
referer header with the URL that made the request.
Uri referrer = Request.UrlReferrer
Keep in mind, here is no guarantee the header is set. Web crawlers or automated requests may not set the referrer header.
Sep 16, 2020 09:38 PM|dlchase|LINK
Cool. I can pull the page name from that string then. Thanks.