Advertisement

01.23.2007 at 02:30PM PST, ID: 22133911
[x]
Attachment Details

Forms Authentication

Asked by FirePits in Programming for ASP.NET

Tags: authentication, forms, images

Nothing too complicated....I have a site that uses Forms Authentication with the credentials spelled out in the web.config file. As a result of having the site protected, I cannot display any images on my login.aspx page because the user hasn't authenticated yet. I have research the web and I thought I found the answer, but I cannot get it to work for me. I need access to the images directory (~/images).

Here's my web.config file:

<configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">
    <appSettings/>
    <connectionStrings/>
    <system.web>
        <compilation debug="false" />
      <authentication mode="Forms">

        <forms loginUrl="Login.aspx" path="/"  timeout="30" protection="All">

          <credentials passwordFormat="Clear">

            <user name="SiteUser" password="pw" />

          </credentials>

        </forms>

      </authentication>

      <authorization>
        <deny users="?" />
      </authorization>
    </system.web>
     
     
      <location path="~/images">
          <system.web>
             <authorization>
               <allow users="*" />  
            </authorization>      
        </system.web>
      </location>
   
  </configuration>



Can someone tell me what I am doing wrong???Start Free Trial
[+][-]01.23.2007 at 11:14PM PST, ID: 18383634

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]01.23.2007 at 11:14PM PST, ID: 18383635

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]01.24.2007 at 04:34PM PST, ID: 18392013

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]01.26.2007 at 11:50PM PST, ID: 18409350

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]01.27.2007 at 12:18AM PST, ID: 18409395

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zone: Programming for ASP.NET
Tags: authentication, forms, images
Sign Up Now!
Solution Provided By: farsight
Participating Experts: 2
Solution Grade: A
 
 
[+][-]03.25.2007 at 09:05AM PDT, ID: 18788388

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 7-day free trial to view this Administrative Comment or ask the Experts your question.

 
[+][-]03.25.2007 at 09:32AM PDT, ID: 18788528

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.11.2007 at 02:46PM PDT, ID: 18893720

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 7-day free trial to view this Administrative Comment or ask the Experts your question.

 
[+][-]04.19.2007 at 06:38PM PDT, ID: 18943611

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 7-day free trial to view this Administrative Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32