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

Brittany Wiatrak
PLUS
Brittany Wiatrak
Courses Plus Student 513 Points

I put my own photos in the workspace and I put exactly the codes as in the lesson but it doesn't show up when I preview

I uploaded my photos into the workspace and I put the codes in workspace exactly as learning it in the lesson and when I preview my website it doesn't show the photo, it only shows a little error image box. Here is the code for you to get a better idea of what is going on. I have entered the code exactly as It was done in the video.

<a href="img/GOPR2744-02.jpg"> <img src="img/GOPR2744-02.jpg" alt=""> <p>Underwater Belize </p> </a>

3 Answers

Hugo Paz
Hugo Paz
15,622 Points

If you can show us your code it would be easier for us to help.

Brittany Wiatrak
Brittany Wiatrak
Courses Plus Student 513 Points

I just added the code into the question. Any help would be great

Hugo Paz
Hugo Paz
15,622 Points

For some reason your code is not displaying.

Brittany Wiatrak
Brittany Wiatrak
Courses Plus Student 513 Points

I have no reason why its not showing up because when I edit it shows up there. It doesn't seem to want to show up here either. Grrr

Hugo Paz
Hugo Paz
15,622 Points

Try using the Markdown Cheatsheet to display your code

Brittany Wiatrak
Brittany Wiatrak
Courses Plus Student 513 Points

You are awesome that worked. ok so the code is displayed now, so hopefully someone can help me. Thanks

Hugo Paz
Hugo Paz
15,622 Points

So i tried your code and it works perfectly. So the issue must be related to the image. Either you have the image name wrong or its location is wrong. Check the image filetype to make sure its the correct one, it might be .jpeg.

If the name and type of the file are correct, it must be its location. The root should be something like this:

index.html css.css [img] -- this is a folder and inside you have your image

You may need to add either ../img or ./img or /img before your image name, depending on your file structure :-)

Juan Aviles
Juan Aviles
12,795 Points

Is any part of the picture's file name uppercase? For example is it GOPR2744-02.JPG instead of GOPR2744-02.jpg?