I have a page that can only be accessed by "Admins". If a user who is NOT an admin tries to access the page, I'd like to do two things:
- Log the error to the database
- Send the user to my error page but display a custom message
I don't know where to handle the error logging because there doesn't seem to be a controller for the error page (I'm using Razor. Just created an Internet Application MVC3 project in VS 2010)
I also don't know how to customize the error message.
Could someone give me some pointers on this?
View Complete Post