JSP Images wont display in firefox?

[nobr]Hi,

I need some help. Firefox doesn't seem to display an image coming from a servlet going to a jsp page.

I have this login page. Once the user enters his/her username and password. The servlet will then validate if the credentials are ok.

Once its okay the servlet will forward the username and the image location to home.jsp. Then the home.jsp will render the page.

The problem is only the username gets display its only a text. While the image doesn't get displayed.

I checked the generated page it includes the location of the image but firefox wont display it?

<h3>

Welcome DemoUser

</h3>

<font size="2"><br /><br />

<img src="C:\images\demoimage.jpg">

</font>

b/w I'm using the latest firefox 2.0.1 this problem doesn't occur in IE. IE works well in displaying the desired image.[/nobr]

[976 byte] By [The_Developera] at [2007-11-26 14:55:19]
# 1
Try changing the image tag like this<img src="file:///c:/images/demoimage.jpg" alt="test">works in IE & FFox
Rakesh.TAa at 2007-7-8 8:43:50 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2
I just tried it now and it still did not work, I even hard coded it on the jsp file. Only the alt test shows?
The_Developera at 2007-7-8 8:43:50 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3

I found the solution firefox wont display the image if the image location doesn't start with web application image folder root.

So Instead of C:/Images/image.jpg it should be:

Inside TOMCAT/WebApp/WebApplication it should be:

/images/image.jpg instead.

Message was edited by:

The_Developer

The_Developera at 2007-7-8 8:43:50 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 4
no that is not solution.. it is the behavior of the browser.. different browser has their own characteristics and behaviors
jgalacambraa at 2007-7-8 8:43:50 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...