Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Image is not showing in browser?

Tags:

html

image

jsp

<body style="background-color: paleturquoise">
    <h2 style="color: red">Duke's soccer League: Home Page<br/></h2>
    <ul style="list-style-type: circle">
        <li style="font-size: larger"><a href="league_list.in">All Leagues list</a></li>
        <li style="font-size: larger">Register for a League (TBA)<br/><br/></li>
    </ul>
    <h2 style="color: red">League Administrator</h2>
    <ul style="list-style-type: square">
        <li style="font-size: larger"><a href="add_league.in">Add a new League (TBA)</a></li>

        <img  src="C:\Users\VIRK\Desktop\66.jpg" width="400" height="400" ></img>

</ul>
</body>  

I am currently practice with JSP and I try this html code to make a web page on NetBeans IDE 7.0 but when I'm build and run the page no error in code but the image is not showing in the browser.

Edited:

enter image description here

Here I have given the screenshot of the NetBeans IDE where you can see the image is existing in Web-INF folder and the index.jsp page too and I tried with "/" before the image name but it won't work. The exact path of my project is C:\Users\VIRK\Documents\NetBeansProjects\practiceJSP .

<img  src="/66.jpg" width="400" height="400" ></img>
like image 802
avirk Avatar asked Jun 19 '11 13:06

avirk


People also ask

How do I fix image not showing on website?

If you want to resolve the images not showing problem due to this, then just go to Chrome's Settings > Privacy and Security > Content and select the JavaScript feature. As the dedicated JavaScript section is opened, make sure that the feature is enabled on your browser.

Why is Google Chrome not showing images?

Enable JavaScript in Chrome to Show Pictures Some sites use JavaScript to serve images, and if you've disabled this feature in Chrome, you'll have to turn the option on to see your images. You can turn on JavaScript in Chrome as follows: Launch Chrome, select the three dots at the top-right corner, and choose Settings.


1 Answers

I find out the way how to set the image path just remove the "/" before the destination folder as "images/66.jpg" not "/images/66.jpg" And its working fine for me.

like image 190
avirk Avatar answered Oct 28 '22 04:10

avirk