문제

I am very new to asp.net and c# using web developer express 2010.

I have created a standard web application using web developer express 2010 which comes with membership and roles.

Let say, if i want to create a user with username and password, demo and demo, how do i do that? and for example, let say i want to assign demo role to user, and let demo user to view certain links, how can i do that in asp.net?

In php,

for example,

   if($_POST['username'] == 'demo' && $_POST['password'] == 'demo') {
       $_SESSION['demo'] = true;
   }

   ....

   if($_SESSION['demo'])
       //codes

Please help me thanks

도움이 되었습니까?

해결책

Did you look at this video tutorial : Adding users to your membership system.
http://www.asp.net/web-forms/videos/authentication/adding-users-to-your-membership-system

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top