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 Images, Text and Links Understanding File Paths

Struggling with the file paths.

I can't seem to get my file paths to work. Here is my code:

<a href="articles/2017/article.html">Read more</a>

<li><a href="../../index.html">Home</a></li>

Thank you

Steven Parker
Steven Parker
231,268 Points

This could be a file organization issue, but we need more information to replicate it. Take a look at this video about Posting a Question, and perhaps also this one about sharing a snapshot of your workspace.

2 Answers

Hello Steven, thank you for the suggestion. I took a snapshot of my workspace:

https://w.trhou.se/xg7nceo07g

Steven Parker
Steven Parker
231,268 Points

In the file index.html of the snapshot, the problem with the "Read more" code on lines 46 and 56 above is that the directory name "articles" is spelled with a lower-case "a" when the actual directory name is "Articles". On a case-sensitive filesystem (such as used in the workspaces), these names do not match.

Then in the file article.html of the snapshot, the reference to Home on line 14 is:

      <li><a href=".../.../index.html">Home</a></li>

Notice that the prior directory references are composed of 3 dots, which is not correct. If you use 2 dots (as you showed above in the question) it should work.

Thank you so much Steven, it now works.

Steven Parker
Steven Parker
231,268 Points

Tamara Webster — Glad to help. You can mark a question solved by choosing a "best answer".
And happy coding!