membership provider

J

John

OK, I read and read again information on using the logon control, 'custom
providers' but none are really helping me out with creating a provider to
go against my database to validate the users logging into my web app. What
happens when a user logs into my site is, 8 queries are executed, 1 verfies
the user, and the others get data pertaining to that users id, so drop downs
are populated for that user, etc., So is it possible to use the 2.0
providers to do this same thing, and can someone show me some code of a
provider going against a SQL database (not the membership one 2.0 creates)
your own DB, to validate users loggging into your web app?

going nuts
 
S

sloan

My rudimentary understanding is that the membership provider is for
authentication
updates to info/security/roles etc

http://msdn2.microsoft.com/en-US/library/f1kyba5e.aspx

In your case, I think your login screen needs to use the custom provider..
and then REDIRECT to the next page,
where (because you're verified) you run your routines.
The login screen should be nothing but authentication,, the redirect happens
after you are verified, and the next page does your custom needs.

I'm not sure what db youre using, but .....
If you're running 8 seperate queries, my thoughts would be to put these into
1 stored procedure and populate 1 strongly typed DataSet, with 8 tables in
it.
That way, you're only hitting the db twice.

Once on the verification/login screen.
then REDIRECT
then once to get the 8tables of info.

I think you're barking up the wrong tree trying to have this functionality
merged.

...
 
G

Guest

well, the thing is that I took the existing app from an former developer and
I'm migrating it to 05. The current login screen in asp.net 1.1 is callking
the 8 queries to populate dropdowns, grids, etc on the next page once the
user is verfied. What I'm doing is, I created my login screen and validating
the user only if the user exists in the DB then doing a redirect to the next
page, then doing my processing there.

When I stepped through the current app I noticed what he's doing just on the
login screen alone. He's validatiing the user, then taken the userid and
running 7 more queries to pull data and put into a user object then passing
to queries to load the drop downs, etc.
After thinking about I might be doing it correctly on my version of the
login screen.
because I'm just validating via forms auth.
 

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

Forum statistics

Threads
473,769
Messages
2,569,578
Members
45,052
Latest member
LucyCarper

Latest Threads

Top