Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

HTML How to Make a Website Creating HTML Content Structure the Image Gallery

Using a relative path to insert an image into my site, I am not able to see the actual image. Help? Code is correct.

My code is correct (just as the instructor in the video typed it). However, I am not able to see the image on my site. Could it be that I am missing a certain type of program to display the image?

<li> <img src="image/numbers-01.jpg" alt=""> </li>

3 Answers

Jamie Reardon
seal-mask
.a{fill-rule:evenodd;}techdegree seal-36
Jamie Reardon
Treehouse Project Reviewer

If you have the same copied code as the teacher does and that your folders and files structure is the same, then that means that your path to the image is incorrect. The teacher has made a folder named img not the word image itself.

<img src="img/numbers-01.jpg" alt="">

Make sure that the src attribute has the same correct path value as the folder that the images are in.

I apologize...I should've cleared that up. I did not have the same 'exact' path as the teacher, as you are correct...he has 'img'. I actually had 'Images'. However, I've corrected the broken image issue. My fix was capitalizing my "I" in images. Apparently, it is case-sensitive. Great lesson to have learned.

I've also added the "s" which was missing as well. But even after adding the "s" to images, the "I" had to be capitalized for the image to show on the site (which is how I typed it in the folder...Images

Jamie Reardon
seal-mask
.a{fill-rule:evenodd;}techdegree seal-36
Jamie Reardon
Treehouse Project Reviewer

Yeah, you should be aware of the case-sensitive aspect of naming things. It would probably be better to just use lowercase for everything unless there is a specific reason otherwise.