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 trialAvery Pierce
1,869 PointsCan you assist me with this code anyone? Greatly appreciated!
https://teamtreehouse.com/library/html-basics-2/going-further-with-html/links-and-paths-challenge
<!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
11,546 PointsHi 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
Avery Pierce
1,869 PointsThank you sir.
Avery Pierce
1,869 PointsAvery Pierce
1,869 PointsEric can you tell me how to go one level up? I can't seem to find the example in the lecture.
Eric M
11,546 PointsEric M
11,546 PointsHi Avery,
going one level up is
../
Don't forget that the image folder
img/
is one level upSo to get to
yourfile
in the image folder you would need../img/yourfile
Cheers,
Eric