How do I kill the authentication pop-up window after htaccess failure?

Posted on 2004-11-15
Last Modified: 2012-05-05

I have a "members" section of  our website that is protected using an .htaccess file.  If the user authentication fails, the user is redirected to the standard 401 error. However, for reasons I don't understand, once on this page, the user continues to receive the authentication pop-up window... over and over and over and over.

You can see what happens if you try a failed login. Go to, and try logging in from the home page.

The 401 error page is obviously located outside the protected members area.

Does anyone know why this is happening, and how I can fix it?

Question by:darkyla
    LVL 19

    Accepted Solution

    I think it is a problem in your javascript  file global/code/header_preload.js which is called from you document which is called in case of 401 error. (you have 10 images defined and I just calculated it called 10 times login box)
    their URL is given as menu10_over = newImage("images/header/menu10-over.gif");
    But during login URL is http://site/member/....
    It means that URL for image will be http://site/member/image  and that URL is protected by authentication.
    So change your script. Put leading slash in newImage call:
    menu10_over = newImage("/images/header/menu10-over.gif");


    Author Comment

    LOL... I had no idea.  Thanks.  That seems to have more or less done the job.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Better Security Awareness With Threat Intelligence

    See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

    As Wikipedia explains 'robots.txt' as -- the robot exclusion standard, also known as the Robots Exclusion Protocol or robots.txt protocol, is a convention to prevent cooperating web spiders and other web robots from accessing all or part of a websit…
    If your site has a few sections that need to be secure when data is transmitted between the server and local computer, such as a /order/ section for ordering or /customer/ which contains customer data, etc it would of course be recommended to secure…
    Internet Business Fax to Email Made Easy - With eFax Corporate (, you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
    Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

    759 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

    Need Help in Real-Time?

    Connect with top rated Experts

    8 Experts available now in Live!

    Get 1:1 Help Now