Solved

Visual Studio: Password protect a site

Posted on 2008-10-23
3
214 Views
Last Modified: 2013-11-26
I have a web application created using Visual Studio 2008.  I want users to be denied access to the site if they are not logged in first.  I want the user trying to access a page without logging in to be redirected to the login page.
0
Comment
Question by:sproctor722
  • 2
3 Comments
 
LVL 20

Accepted Solution

by:
brwwiggins earned 125 total points
ID: 22789535
<authentication mode="Forms">
<forms name="AppLogin" loginUrl="login.aspx" path="/" protection="All" timeout="60"></forms>
</authentication>
<authorization>
      <deny users="?" />
 </authorization>
0
 
LVL 20

Expert Comment

by:brwwiggins
ID: 22789559
sorry, hit submit on wrong windows. The above should go in your web.config
0
 

Author Closing Comment

by:sproctor722
ID: 31509354
You're fantastic!  Thank you!!!!!
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Flash (http://en.wikipedia.org/wiki/Adobe_Flash) has evolved over the years to where it has become a masterful tool for displaying content screen.  It has excellent layout placement, UI precision as well as rendering capabilities. This, along with t…
It seems a simple enough task, yet I see repeated questions asking how to do it: how to pass data between two forms. In this article, I will show you the different mechanisms available for you to do just that. This article is directed towards the .N…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question