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 Introduction to HTML and CSS (2016) Adding a New Web Page Write the CSS

I am having trouble with previewing my resume.

I tried adding /resume.html to the url of the original Profile Page but I keep getting a "404- not found error message." Edit: The problem is not with the code but the url in the browser. It can't find the resume I'm creating to allow me to preview it.

2 Answers

Hi Theresa,

Did you manage to figure this out?

Most people with this issue seem to be naming their "Resume.html" with a capital "R", which causes a 404 error as workspace URLs are actually case sensitive (something that isn't mentioned in the video).

I saw in your GitBHub that your HTML file was lowercase. Is there any possibility that you had it named "Resume.html" in your workspace but inadvertently changed it to "resume.html" in your GitHub? This seems a trivial detail but a case mismatch between what you type in your browser's address bar and how your workspace file is named will throw a 404 error every time!

Try typing your URL the same as before but as "/Resume.html" (capital first letter) and also try looking in your workspace and changing the file name from "Resume.html" to "resume.html" if it was capitalized.

ale8k
ale8k
8,299 Points

If the file you're targeting is in the same folder, you do not use a forward slash '/'. This tells it to initially look for root. Here is a snippet from w3 schools. I hope this helps:

<img src="picture.jpg"> picture.jpg is located in the same folder as the current page
<img src="images/picture.jpg">  picture.jpg is located in the images folder in the current folder
<img src="/images/picture.jpg"> picture.jpg is located in the images folder at the root of the current web
<img src="../picture.jpg">  picture.jpg is located in the folder one level up from the current folder

Further more, here is where I sourced the information I just given you: https://www.w3schools.com/html/html_filepaths.asp

Unfortunately, the issue is with what's displaying on the browser and not a linked image code. This is my code on Github

The "/resume.html" appended to the URL was what was being typed in Theresa's browser, rather than something that was appended to a path defined in an "src" attribute. Hence: "...adding to the url of the original Profile Page".

Besides, any problem with an <img> element inside an HTML file would not explain a 404 "Page not found" error when trying to open the HTML page itself - the browser isn't getting as far as reading the HTML file.