Weird issue with Login Control and Authentication

C

CarlosSanchezJr

Quick background on what I'm using:

Visual Web Developer 2005
SQL Server Express 2005
Hosted on my local machine (this is just a "get used to 2.0" test
website)

I have created the membership (?) schema in my existing Express 2005
database. That has went well. I have two users in that database, both
assigned to the role, "Administrators".

I have a login control inside a user control that is either persistent
across the pages (via Master Page) or in a Login.aspx page. Now here
is where the weirdness kicks in. If I go into debug mode from VWD and
attempt to login, everything works just fine. However, if I go to that
website directly via "http://localhost/" (I have IIS pointed to that
folder), the rest of the website works great, but no matter how many
times I try and with what user accounts I try with, I get the standard
"Your login attempt was not successful. Please try again." message the
Login Control kicks back out to you.

I've checked the database and it is not recording login attempts while
this is happening. It has me going bonkers! Any ideas?
 
P

PeterKellner

Quick background on what I'm using:

Visual Web Developer 2005
SQL Server Express 2005
Hosted on my local machine (this is just a "get used to 2.0" test
website)

I have created the membership (?) schema in my existing Express 2005
database. That has went well. I have two users in that database, both
assigned to the role, "Administrators".

I have a login control inside a user control that is either persistent
across the pages (via Master Page) or in a Login.aspx page. Now here
is where the weirdness kicks in. If I go into debug mode from VWD and
attempt to login, everything works just fine. However, if I go to that
website directly via "http://localhost/" (I have IIS pointed to that
folder), the rest of the website works great, but no matter how many
times I try and with what user accounts I try with, I get the standard
"Your login attempt was not successful. Please try again." message the
Login Control kicks back out to you.

I've checked the database and it is not recording login attempts while
this is happening. It has me going bonkers! Any ideas?

Make sure you have applicationName set in your web.config. Example
below:

<membership defaultProvider="SqlMembershipProvider"
userIsOnlineTimeWindow="15">
<providers>
<clear/>
<add name="SqlMembershipProvider" applicationName="appname"
....
</membership>
Peter Kellner
http://peterkellner.net
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,982
Messages
2,570,186
Members
46,740
Latest member
JudsonFrie

Latest Threads

Top