/ Published in: C#
                    
                                        
Segments is a zero based array that starts with the first segment.
                
                            
                                Expand |
                                Embed | Plain Text
                            
                        
                        Copy this code and paste it in your HTML
if (address.Segments[0] == "Admin") //do something...
string path = HttpContext.Current.Request.Url.AbsolutePath;
// /TESTERS/Default6.aspx
string host = HttpContext.Current.Request.Url.Host;
// localhost
Comments
 Subscribe to comments
                    Subscribe to comments
                
                