470,636 Members | 1,462 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,636 developers. It's quick & easy.

Membership Problem

Hi, I have a membership problem I couldn't resolve. I have set up membership
as most of tutorial instructed, and I am able to log on, but cannot stay log
on for some reason. ex: when I log on, the log in become log on, but when I
access the protected page, it still prompt me for log in. Please help!

I am using SQL to store the membership,

the code in web.config is as follow,

<roleManager enabled="true"/>
<authentication mode="Forms"/>
<membership defaultProvider="MembershipProvider">
<providers>
<add name="MembershipProvider"
type="System.Web.Security.SqlMembershipProvider"
connectionStringName="DataConnection" minRequiredPasswordLength="5"
minRequiredNonalphanumericCharacters="0"/>
</providers>
</membership>

Aug 25 '06 #1
6 1742
Do you have an <authorizationsection? If so what does it look like?

Kevin

Scatir wrote:
Hi, I have a membership problem I couldn't resolve. I have set up membership
as most of tutorial instructed, and I am able to log on, but cannot stay log
on for some reason. ex: when I log on, the log in become log on, but when I
access the protected page, it still prompt me for log in. Please help!

I am using SQL to store the membership,

the code in web.config is as follow,

<roleManager enabled="true"/>
<authentication mode="Forms"/>
<membership defaultProvider="MembershipProvider">
<providers>
<add name="MembershipProvider"
type="System.Web.Security.SqlMembershipProvider"
connectionStringName="DataConnection" minRequiredPasswordLength="5"
minRequiredNonalphanumericCharacters="0"/>
</providers>
</membership>
Aug 25 '06 #2
My authorization section is as follows:

<authorization>
<deny users="*" />
<allow roles="admin" />
<allow roles="trader" />
</authorization>

"Kevin Jones" wrote:
Do you have an <authorizationsection? If so what does it look like?

Kevin

Scatir wrote:
Hi, I have a membership problem I couldn't resolve. I have set up membership
as most of tutorial instructed, and I am able to log on, but cannot stay log
on for some reason. ex: when I log on, the log in become log on, but when I
access the protected page, it still prompt me for log in. Please help!

I am using SQL to store the membership,

the code in web.config is as follow,

<roleManager enabled="true"/>
<authentication mode="Forms"/>
<membership defaultProvider="MembershipProvider">
<providers>
<add name="MembershipProvider"
type="System.Web.Security.SqlMembershipProvider"
connectionStringName="DataConnection" minRequiredPasswordLength="5"
minRequiredNonalphanumericCharacters="0"/>
</providers>
</membership>
Aug 25 '06 #3
And I assume you're login is in either the "admin" or "trader" role?
Kevin Jones

Scatir wrote:
My authorization section is as follows:

<authorization>
<deny users="*" />
<allow roles="admin" />
<allow roles="trader" />
</authorization>

"Kevin Jones" wrote:
>Do you have an <authorizationsection? If so what does it look like?

Kevin

Scatir wrote:
>>Hi, I have a membership problem I couldn't resolve. I have set up membership
as most of tutorial instructed, and I am able to log on, but cannot stay log
on for some reason. ex: when I log on, the log in become log on, but when I
access the protected page, it still prompt me for log in. Please help!

I am using SQL to store the membership,

the code in web.config is as follow,

<roleManager enabled="true"/>
<authentication mode="Forms"/>
<membership defaultProvider="MembershipProvider">
<providers>
<add name="MembershipProvider"
type="System.Web.Security.SqlMembershipProvide r"
connectionStringName="DataConnection" minRequiredPasswordLength="5"
minRequiredNonalphanumericCharacters="0"/>
</providers>
</membership>
Aug 28 '06 #4
Ya, I login as admin role, but only the login will change to logout, when I
try to access any page, it will still prompt me for login.

"Kevin Jones" wrote:
And I assume you're login is in either the "admin" or "trader" role?
Kevin Jones

Scatir wrote:
My authorization section is as follows:

<authorization>
<deny users="*" />
<allow roles="admin" />
<allow roles="trader" />
</authorization>

"Kevin Jones" wrote:
Do you have an <authorizationsection? If so what does it look like?

Kevin

Scatir wrote:
Hi, I have a membership problem I couldn't resolve. I have set up membership
as most of tutorial instructed, and I am able to log on, but cannot stay log
on for some reason. ex: when I log on, the log in become log on, but when I
access the protected page, it still prompt me for log in. Please help!

I am using SQL to store the membership,

the code in web.config is as follow,

<roleManager enabled="true"/>
<authentication mode="Forms"/>
<membership defaultProvider="MembershipProvider">
<providers>
<add name="MembershipProvider"
type="System.Web.Security.SqlMembershipProvider "
connectionStringName="DataConnection" minRequiredPasswordLength="5"
minRequiredNonalphanumericCharacters="0"/>
</providers>
</membership>
Aug 28 '06 #5
>><authorization>
>> <deny users="*" />
<allow roles="admin" />
<allow roles="trader" />
</authorization>

You're denying all users!

You probably want the order changed
>><authorization>
<allow roles="admin" />
<allow roles="trader" />
<deny users="*" />
</authorization>

Scatir wrote:
Ya, I login as admin role, but only the login will change to logout, when I
try to access any page, it will still prompt me for login.

"Kevin Jones" wrote:
>And I assume you're login is in either the "admin" or "trader" role?
Kevin Jones

Scatir wrote:
>>My authorization section is as follows:

<authorization>
<deny users="*" />
<allow roles="admin" />
<allow roles="trader" />
</authorization>

"Kevin Jones" wrote:

Do you have an <authorizationsection? If so what does it look like?

Kevin

Scatir wrote:
Hi, I have a membership problem I couldn't resolve. I have set up membership
as most of tutorial instructed, and I am able to log on, but cannot stay log
on for some reason. ex: when I log on, the log in become log on, but when I
access the protected page, it still prompt me for log in. Please help!
>
I am using SQL to store the membership,
>
the code in web.config is as follow,
>
<roleManager enabled="true"/>
<authentication mode="Forms"/>
<membership defaultProvider="MembershipProvider">
<providers>
<add name="MembershipProvider"
type="System.Web.Security.SqlMembershipProvide r"
connectionStringName="DataConnection" minRequiredPasswordLength="5"
minRequiredNonalphanumericCharacters="0"/>
</providers>
</membership>
>
Aug 28 '06 #6
It seem to solve the problem. Thanks.

"Kevin Jones" wrote:
>><authorization>
>> <deny users="*" />
>> <allow roles="admin" />
>> <allow roles="trader" />
>></authorization>


You're denying all users!

You probably want the order changed
>><authorization>
>> <allow roles="admin" />
>> <allow roles="trader" />
>> <deny users="*" />
>></authorization>


Scatir wrote:
Ya, I login as admin role, but only the login will change to logout, when I
try to access any page, it will still prompt me for login.

"Kevin Jones" wrote:
And I assume you're login is in either the "admin" or "trader" role?
Kevin Jones

Scatir wrote:
My authorization section is as follows:

<authorization>
<deny users="*" />
<allow roles="admin" />
<allow roles="trader" />
</authorization>

"Kevin Jones" wrote:

Do you have an <authorizationsection? If so what does it look like?

Kevin

Scatir wrote:
Hi, I have a membership problem I couldn't resolve. I have set up membership
as most of tutorial instructed, and I am able to log on, but cannot stay log
on for some reason. ex: when I log on, the log in become log on, but when I
access the protected page, it still prompt me for log in. Please help!

I am using SQL to store the membership,

the code in web.config is as follow,

<roleManager enabled="true"/>
<authentication mode="Forms"/>
<membership defaultProvider="MembershipProvider">
<providers>
<add name="MembershipProvider"
type="System.Web.Security.SqlMembershipProvider "
connectionStringName="DataConnection" minRequiredPasswordLength="5"
minRequiredNonalphanumericCharacters="0"/>
</providers>
</membership>
Aug 29 '06 #7

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by John | last post: by
9 posts views Thread by Paul Keegstra | last post: by
5 posts views Thread by Vishal Gupta | last post: by
3 posts views Thread by ryan.mclean | last post: by
4 posts views Thread by =?Utf-8?B?Q2hyaXMgQ2Fw?= | last post: by
4 posts views Thread by Ben | last post: by
1 post views Thread by =?Utf-8?B?ZVByaW50?= | last post: by
1 post views Thread by =?Utf-8?B?ZVByaW50?= | last post: by
1 post views Thread by Korara | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.