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 Build the Footer

Pictures Cannot be Displayed

Hi,

I am having some problems in my workspace website. My photos could not be displayed in the preview webpage (a small image picture is displayed as an error instead) although when clicked, it displays out the full picture as taught in the video. Pls help.

Thanks

6 Answers

I think I figured out the error. Thanks Chris. :)

Amr Tag
Amr Tag
5,429 Points

I'm going to type in what happened to me, shall anyone repeat my errors and stumble upon this discussion

in the src attribute, make sure you are the correct link to the image (most links end in .jpg or .png or similar extensions, trying to get images off of websites, like Facebook, might not work well)...also, if you are using a relative link, make sure you don't go up in directories so far (by typing ../ you go up one file or a directory), going up too far might result in getting images from other projects (if you have multiple projects in the same code-editor application you are using). Also, file extensions are part of the link, I forget adding .jpg or .png sometimes and it gives broken images. Hope this helps anyone who might make the same mistakes as I did

Is there any chance you can upload your code. Either here or to codepen.io . It may help.

Apologies, I didn't realise that the text boxes would format the html. Maybe try putting it on codepen, if you can.

Congrats! Always better figuring it out yourself anyway. :)

Couldn't copy and paste the code. It does not display the code here.

James Barnett
James Barnett
39,199 Points

The forum uses markdown to correctly format code, check out this thread on how to type code in the forum for some examples.