Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9257543
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T12:10:48+00:00 2026-06-18T12:10:48+00:00

I am developing an ASP .Net website. I have created 2 ASPX pages and

  • 0

I am developing an ASP .Net website.
I have created 2 ASPX pages and 1 master page.
My 2 ASPX pages are content pages associated to the master page.
My 2 ASPX pages are : MainMenu.aspx and Authentication.aspx.
Authentication.aspx is my login page.

I have created a theme for my website.
My theme is made up of a CSS file.
I have added the following element in my web.config file to automatically import my CSS file :

<pages styleSheetTheme="Default" />

My CSS file was correctly imported until I configure authorization in my web.config file as follows :

<configuration>
    <system.web>

        ...

        <pages styleSheetTheme="Default" />

        <authentication mode="Forms">
          <forms loginUrl="~/Authentication.aspx" defaultUrl="~/MainMenu.aspx">
          </forms>
        </authentication>

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

  <location path="~/Authentication.aspx">
    <system.web>
      <authorization>
        <allow users="?" />
      </authorization>
    </system.web>
  </location>
</configuration>

The purposes of my authorization configuration are :

  • Allow any users to access to my login page – Authentication.aspx
  • Allow only authenticated users to access to pages other than my login page

If I comment the authentication, authorization and location elements then my CSS file is correctly imported again.

What is wrong with my authorization configuration ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T12:10:49+00:00Added an answer on June 18, 2026 at 12:10 pm

    Someone has explained me the reason of my problem:

    1. A request was sent to the server when loading the authentication page.
    2. The request aimed the CSS file.
    3. But the CSS file was located in a folder restricted to unauthenticated users.

    Therefore the request failed.

    How I have solved my problem:

    • I have put all the restricted files into a common folder.
    • I have created a web.config file into the folder to allow access only to authenticated users.
    • I have removed authorization and location elements from my website root web.config file.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am developing a website by ASP.Net. I have created settings/first-run page which I
I am developing a website using ASP.NET 4.0 and SQL Server 2008.In Login Page,
I am developing an ASP.NET 2.0 website. I have created data access and business
i am developing a website using asp.net 3.5.i have created a cascading dropdownlist for
i have a problem i am developing an asp.net mvc project. Website is in
People, I am in developing an asp.net website with a Multilanguage content and SEO
I'm developing a new website (ASP.Net, VB codebehind pages, .Net 3.5) to replace a
I have an asp.net c# website I'm developing with Visual Web Developer Express Edition
I am developing a website in asp.net and have this problem: string price =
I'm developing a website (using asp.net-mvc) with a SqlServer 2005 database. I have numerous

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.