473,322 Members | 1,806 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,322 software developers and data experts.

how to redirect a login page even we open a other pages

8
hi friends i want to open a login page first even for accessing any other pages in the application.
my code in web.config:
<authentication mode="Forms">
<forms loginUrl="~/Pages/login.aspx" defaultUrl ="~/Pages/default2.aspx" protection ="Validation" timeout="30"/>
</authentication>
<authorization>


<deny users ="?"/>

</authorization>
<location path ="~/Pages/default2.aspx">
<system.web >
<authorization >


<deny users="?"/>
</authorization>
</system.web>
</location>
<location path ="~/Pages/DepartmentMain.aspx">
<system.web >
<authorization >


<deny users ="?"/>
</authorization>
</system.web>
</location>

plz help me with code
Feb 19 '07 #1
1 1103
kenobewan
4,871 Expert 4TB
Here is an article that may help:
How to: Create an ASP.NET Login Page
Feb 20 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

5
by: Simon | last post by:
Hi, I have a Login.php page that logs the user in and out. I has two forms within the page, (depending on what we are trying to do), either one to log in or out. The form calls itself using a...
3
by: William Sullivan | last post by:
Have a frameset HTML page (parent) with child .aspx pages. When each of the child pages loads, it checks to see if the user is authenticated, and if not, redirects to the login page: ...
4
by: Greg Scharlemann | last post by:
I thought I had a workable approach to specifing which pages required a redirect in a config file, but it appears the way I'm attempting to do it is not going to work. The idea is that I can...
3
by: j-in-uk | last post by:
Hi, I'm using the login control for asp.net 2.0. Once a user logs in I want to set timeouts for certain pages not the whole app, so if the page they on has expired I want to redirect the user...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work

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.