Greetings:
I am presently working on building an ASP.NET MVC application. I am quite new to .NET applications so please forgive my ignorance.
I am using a Controller method/action (called SetHeader()) to display a different set of links within the header based upon whether a user is logged in or not. This works fine with two exceptions - right after the user logs and logs out. Therefore, I am looking for a way, within the SetHeader() action, to determine if the user is being directed to the current page by the Login and Logout actions I have created. What is a good way to accomplish this?
Thanks so much!
What I have tried:
I have tried Request.UrlReferrer.ToString(); however, the results were not exactly what I hoped for. I just need a simple way to check if the request was made by either the Login or Logout actions.