string.Format("{0:£0,0.00}", 12.012)
<globalization requestEncoding="utf-8" responseEncoding="utf-8" culture="en-GB" uiCulture="en-GB" />
string url = HttpContext.Current.Request.Url.AbsoluteUri;
// http://localhost:1302/TESTERS/Default6.aspx
Get Application name and page name:
string path = HttpContext.Current.Request.Url.AbsolutePath;
// /TESTERS/Default6.aspx
Get Application Rooth path:
string host = HttpContext.Current.Request.Url.Host;
// localhost
Response.Write(Request.ApplicationPath)
Address:http://localhost/basiclayout/
/basiclayout
Response.Write(HttpContext.Current.Request.Url.Host+Request.ApplicationPath);
Get Full URL:
Request.Url.ToString()
// http://localhost:1302/TESTERS/Default6.aspx?page=1
URI variable:
Uri uri= HttpContext.Current.Request.Url;
String host = uri.Scheme + Uri.SchemeDelimiter + uri.Host + ":" + uri.Port;