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

My 'articles' page is still showing 404 Not Found in HTML Basics Track

I thought I found the error. I didn't. I've spent the last 3.5 hours scouring vids and the code itself to correct this. Does anyone see something missing? The entire 'articles' code is below:

<!DOCTYPE html>
<html>
  <head>
    <title>VR Article</title>
  </head>

  <body>
    <div>
    <header>
      <h1>Experience VR</h1>
      <p>A simple blog about virtual reality experiences</p>

      <nav>
        <ul>
            <li><a href="/index.html">Home</a></li>
            <li><a href="/index.html#about">About</a></li>
            <li><a href="/index.html#articles">Articles</a></li>
            <li><a href="/index.html#contact">Contact</a></li>
        </ul>  
        </nav> 
       </header>

      <article id="vr-article">        
      <header>
       <h2>VR Article</h2>
       <p>By: Nick Petit</p> 
       <p>Published: June 19, 2017</p> 
      </header>        

      <img src="/img/vr-user.jpg" alt="User trying a VR headset">
        <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus ultrices euismod turpis eget porta. Etiam nulla massa, pretium et massa nec, ornare dignissim nisi.</p>
        <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus ultrices euismod turpis eget porta. Etiam nulla massa, pretium et massa nec, ornare dignissim nisi.</p> 
        <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus ultrices euismod turpis eget porta. Etiam nulla massa, pretium et massa nec, ornare dignissim nisi.</p> 

     </article>   

    <article>
    <h2>VR Article</h2>     
      <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus ultrices euismod turpis eget porta. Etiam nulla massa, pretium et massa nec, ornare dignissim nisi.</p> 

      <aside>
      <q>This is a pull quote from the VR aticle</q>
        <ul>
          <li><a href="#"></a>Make a VR game</li>
          <li><a href="#"></a>Learn VR in Unity</li>
          <li><a href="#"></a>Build user interface in VR</li>
        </ul>

      </aside>
            <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus ultrices euismod turpis eget porta. Etiam nulla massa, pretium et massa nec, ornare dignissim nisi.</p> 
      <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus ultrices euismod turpis eget porta. Etiam nulla massa, pretium et massa nec, ornare dignissim nisi.</p> s
    </article>

    <aside>
      <h3>More articles about VR</h3>
        <ul>
          <li></li>
        </ul>
      </aside>




      <footer>
      <p>&copy;2017 Experience VR, The Blog</p>
      </footer>

    </div>
    </body>
</html>

Thanks in advance!

Just offhand I'd say check the spelling of the filename. Did you perhaps name it "vr-articles" instead of "vr-article"?

5 Answers

Hi Shari. A couple of times when things weren't working after I stepped away for a moment, I just had to close the pages and reopen. Then things were back to working properly again. But if that doesn't do it...

So, in your "index.html" page there is a link to your "article.html" page. The link in the index page, the anchor tag that surrounds the "Learn More" text says exactly what?

I think you should check to make sure that the syntax of the href attribute is correct. (For example, if you put a space between the filename and the #vr-article, the file will not be found. No space is allowed)

I think you should check to make sure that the path and filename in the link are the same as the actual path and filename. (For example if you created a folder named "Articles", but you refer to the folder in your link as "articles", the file will not be found.)

Did you move the article page to a sub-folder of the "img" folder, but forget to update the link?

Yiks! When I try to preview my article.html, the index page opens instead. I don't know what happened. Any ideas?

Just offhand I'd say check the spelling of the filename. Did you perhaps name it "vr-articles" instead of "vr-article"?

Also, is the "articles page" in the same folder as the html document that refers to it? You may need to include a path in your id attribute.

THIRD IDEA: Apparently capitalization matters in html references to filenames and paths. Does the name or path have any capital letters?

No. Two different folders.