I have a Master page for my site that is used for styling the rest of the site and doing user authentication. This works fine except that I have one page that I would like to retain the styling from the master but not do the authentication since this is the page that tells the user that they aren't authenticated. How could I override the MasterPage's Page_Load method from this one page? Any other thoughts on how I could not authenticate on this one page without moving authentication from the master?
+1
A:
Maybe check in your master page somewhere in Request.Current.Url for the current page name (Whatever.aspx) and skip authentication for it.
Developer Art
2010-01-25 16:00:32
+1
A:
You can create a property on your master page that defaults to true, meaning that authenitcation should happen. You can then set that property inside of the initialization logic for the single page to false. When the master page tries to do authentication, it should first check for the state of this property.
For an example of how to communicate with a master page like this, take a look at the Abstract Interaction section of this article.
Chris
2010-01-25 16:04:28