Reputation: 5384
Imagine i have a control (or partial view) that needs to display differently depending on what page it is.
How can I know both at the Server and Client level on what page I am?
Upvotes: 0
Views: 69
Reputation: 15890
On the server (ASP.NET & MVC):
Request.Url
On the client using Javascript:
window.location
Upvotes: 1