Creating Absolute URLs for cookieless sessions (VB.net) : URI URL « Response « ASP.Net






Creating Absolute URLs for cookieless sessions (VB.net)

<%@ Page Language="vb" %>
<html>
   <head>
      <title>Creating Absolute URLs for cookieless sessions in ASP.NET</title>
      <script runat="server">
         Sub Page_Load()
            Dim NewPath As String
            NewPath = Request.Url.Scheme & "://" & Request.Url.Host & _
               Response.ApplyAppPathModifier(Request.Url.AbsolutePath)
            Message.Text = "Modified Absolute URL = " & NewPath
         End Sub
      </script>
   </head>
<body>
   <asp:label id="Message" runat="server"/>
</body>
</html>
           
       








Related examples in the same category

1.Displaying URL information: Scheme (VB.net)
2.Displaying URL information: Port (VB.net)
3.Displaying URL information: Host (VB.net)
4.Referral URL info (VB.net)