473,387 Members | 1,553 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

several login pages

Hi,

Got an asp.net application and I use the "forms" authentication mode defined
in the web.config file.

Everything works fine.
But now I would like to add a second, different login page for the users
that go in a specific folder.
How can I do this?

I tried this:

my root web.config contains:
-----------------------------
<authentication mode="Forms">
<forms name="GLWEB.ASPXAUTH"
loginUrl="login.aspx"
protection="All"
timeout="500"
path="/"
/>
</authentication>

<authorization>
<allow users="*" />
<deny users="?" />
</authorization>
-----------------------------

But for the folder /members I want another login page, so I inserted this in
the web.config in the folder /members:
-----------------------------
<authentication mode="Forms">
<forms name="GLWEB.ASPXAUTH"
loginUrl="/members/login.aspx"
protection="All"
timeout="500"
path="/"
/>
</authentication>

<authorization>
<allow roles="member" />
<deny users="*" />
</authorization>
-------------------------------

Hope someone can help me.
THX !

Nov 18 '05 #1
1 1223
Nicholas,

If you want to do that then you'll have to make your sub-folder it's own
application in IIS. You are probably getting the "MachineToApplicationError"
when you access the sub-folder now, correct?

- Frank Mamone
"nicholas" <mu********@hotmail.com> wrote in message
news:OD**************@TK2MSFTNGP12.phx.gbl...
Hi,

Got an asp.net application and I use the "forms" authentication mode defined in the web.config file.

Everything works fine.
But now I would like to add a second, different login page for the users
that go in a specific folder.
How can I do this?

I tried this:

my root web.config contains:
-----------------------------
<authentication mode="Forms">
<forms name="GLWEB.ASPXAUTH"
loginUrl="login.aspx"
protection="All"
timeout="500"
path="/"
/>
</authentication>

<authorization>
<allow users="*" />
<deny users="?" />
</authorization>
-----------------------------

But for the folder /members I want another login page, so I inserted this in the web.config in the folder /members:
-----------------------------
<authentication mode="Forms">
<forms name="GLWEB.ASPXAUTH"
loginUrl="/members/login.aspx"
protection="All"
timeout="500"
path="/"
/>
</authentication>

<authorization>
<allow roles="member" />
<deny users="*" />
</authorization>
-------------------------------

Hope someone can help me.
THX !

Nov 18 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Rujuta Gandhi | last post by:
Hi All, I am facing a very crucial problem. Im developing a web application using .net studio 2005(beta). I want my Login.aspx page to be secured(https) for encrypted login information...
4
by: nicholas | last post by:
Hi, Got an asp.net application and I use the "forms" authentication mode defined in the web.config file. Everything works fine. But now I would like to add a second, different login page for...
9
by: eitan | last post by:
Hello, I am using Microsoft Visual Studio 2003 .NET. I have several question, please. 1) I have a connection to the database, which I create it at login, by application("conMain") (I have...
1
by: Joe | last post by:
Dear all, I have many questions, please help! 1.) If i use the backup/restore function in the IIS, does the backup includes only the register and settings of web sites in the IIS only, or does it...
1
by: Jakob Lithner | last post by:
When I started a new ASP project I was eager to use the login facilities offered in Framework 2.0/VS 2005. I wanted: - A custom principal that could hold my integer UserID from the database -...
6
by: AppleBag | last post by:
I'm having the worst time trying to login to myspace through code. Can someone tell me how to do this? Please try it yourself before replying, only because I have asked this a couple of times in...
4
by: sonali.noni | last post by:
Hi, I'm very new to DotNetNuke and asp.net, and having several major issues. I'd really appreciate any help you could give me! I'm using DotNetNuke 04.05.03 and asp.net 2.0 I have two...
3
by: =?Utf-8?B?RHVrZSAoQU4yNDcp?= | last post by:
The majority of pages on our site need authentication (forms auth against the aspnetdb database). I created an '~/auth' folder with its own config file forcing authentication for any pages in the...
10
by: DavidPr | last post by:
When I logout as one user and log in under a different user, it opens with the last user's information. User 1 - Unsername: Davey Jones User 2 - Unsername: David Smith I log out from Davey...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.