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 HTML Basics Going Further with HTML Links and Paths Challenge

Can you assist me with this code anyone? Greatly appreciated!

https://teamtreehouse.com/library/html-basics-2/going-further-with-html/links-and-paths-challenge

index.html
<!DOCTYPE html> 
<html>
  <head>
    <title>Portfolio Page</title>
  </head>
  <body>
    <img src=/../.."/logo.png" alt="Site logo">
    <ul>
      <li><a href="">Home</a></li>
      <li><a href="">Portfolio</a></li>                
    </ul>
    <h1 id="portfolio">My Portfolio</h1>
  </body>
</html>

2 Answers

Eric M
Eric M
11,545 Points

Hi Avery,

The entire string after src= in the img tag should be enclosed in quotation marks.

e.g.

<img src="../image.png">

Also note that the challenge is to go one level up and into a folder named img. So the img folder will need to be in the path before the filename.

Best of luck,

Eric

Eric can you tell me how to go one level up? I can't seem to find the example in the lecture.

Eric M
Eric M
11,545 Points

Hi Avery,

going one level up is ../

Don't forget that the image folder img/ is one level up

So to get to yourfile in the image folder you would need ../img/yourfile

Cheers,

Eric

Thank you sir.