Link to home
Start Free TrialLog in
Avatar of Rick
Rick

asked on

asp.net - How to verify is user has permission to access page?

In a asp.net website that uses "Forms" authentication, how do I verify if a user has permission to access a page?

Usually, if a user doesn't have permission to access a page, he/she gets redirected to the default login page. How do I check if he/she has permission to access a page before he/she gets redirected to login?
Avatar of ajb2222
ajb2222

Avatar of Rick

ASKER

How to check if a user is in a specific role before he/she gets redirected to login?
What exactly you are looking for ...apart from knowing if user is authorized to access the page?
Avatar of Rick

ASKER

If the user is not authorized to access the page, then redirect him/her to some page (other than the login page).
ASKER CERTIFIED SOLUTION
Avatar of guru_sami
guru_sami
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Rick

ASKER

Very nice! Thank you.