I am running a website on a virtual directory.
The url for the site is http://localhost/virtalDirectory/pages.aspx
I have an image to be loaded on the page from the following directory heirarchy:
parent directory
..images
....my image
..myPage.aspx
My img tag is
<img src="images/imageName.gif" alt="some text"/>
When loading in IE8, the images are loaded properly, but when loading in Firefox3 I am prompted to log into localhost and it appears to be a windows file explorer login.
I have a web.config in the images directory:
<system.web>
<authorization>
<allow users="*" />
</authorization>
</system.web>
I have tried changing my image tag to:
<img src="~/images/imageName.gif" alt="some text" runat="server"/> to allow asp to resolve the address of the image at run-time. Which does not resolve the problem.
I have tried adding <allow users="?" /> to the image directory web.config. Which does not resolve the problem.
Have you checked the permissions on the file itself? Most likely, the file permissions are set to you vs. everyone, and IE passes the credentials along but Firefox doesn’t.