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

No Image Appearing

Hello! This is in the basic stages of HTML / CSS, but I'm creating an img tag for the Smells Like Bakin' Cupcake Company. For some reason, my image is not showing up. I have checked the code several times and it appears the same as the instructional video.

Help please! Maybe I need another set of eyes :) Even in the quiz my img tag isn't taking..

Thank you!

  <img src="img/logo.gif" alt="Smells Like Bakin">

3 Answers

Do you have the image in an image folder in you project.

I actually did forget to download the zip! Thank you for your help :)

<!DOCTYPE HTML>
<html>
<head>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> 
  <title>Smells Like Bakin' Cupcake Company</title>
</head>
<body>
  <img src="img/logo.gif" alt="Smells Like Bakin">
  <ul class="nav">
    <li><a href="#">About</a></li>
    <li><a href="#">Cupcakes & Prices</a></li>
    <li><a href="#">Locations</a></li>
    <li class="last"><a href="#">Contact Us</a></li>
  </ul>
</body>
</html>

Hi all!

Same issue, only I already downloaded the zip file! Wondering if I need to change the folder's location? I moved it from "Downloads" to my desktop. I also just copied and pasted the code from Becca just to see if I had messed it up somewhere, and still no image. Help?

Thanks!

Kristin

Hi Kristin,

What I found to work is this:

Example, your main folder is "Design" or "HTML" with your index.html and other files in there. I had to place the img file directly into the main folder, not into the css folder. Otherwise the src=img wouldn't pick it up, if it was nested within too many files. Just move your img folder into a main folder beside your css & index.html - that worked for me!

Got it! Great! Thanks so much Becca! Happy learning :)

You too! So happy everyone can help each other :)

Hello, I had a question about the <img> tag also. I downloaded the image files to my desktop and when I put in the <img src="/desktop/img/logo.gif": I'm getting told it's wrong. However when I put 2 periods like this<img src="../desktop/img/logo.gif" alt="Smells Like Bakin"> in front of desktop it works. I was wondering what those periods mean? Also is that normal syntax?