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!
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
Ryan Fukuhara742 Points
About page doesn't work (404 error)
I copied and pasted the index.html code into the about.html page and saved. When I clicked the about page it says 404 error.
is there something wrong in my code?
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <link rel="stylesheet" href="css/normalize.css"> <link href='http://fonts.googleapis.com/css?family=Changa+One:400,400italic|Open+Sans:700italic,400,700,800' rel='stylesheet' type='text/css'> <link rel="stylesheet" href="css/main.css"> <title>Ryan Fukuhara | Web Design</title> </head> <body> <header> <a href="index.html" id="logo"> <h1>Ryan Fukuhara</h1> <h2>Web Design</h2> </a> <nav> <li><a href="index.html"class="selected">Portfolio</a></li> <li><a href="About.html">About</a></li> <li><a href="Contact.html">Contact</a></li> </nav> </header> <div id="wrapper"> <section> <ul id="gallery"> <li> <a href="IMG/numbers-01.jpg"> <img src="IMG/numbers-01.jpg" alt=""> <p>Experimentation with colors and textures</p> </a> </li> <li> <a href="IMG/numbers-02.jpg"> <img src="IMG/numbers-02.jpg" alt=""> <p>Photoshop stuff</p> </a> </li> <li> <a href="IMG/numbers-06.jpg"> <img src="IMG/numbers-06.jpg" alt=""> <p>Trying to make 80's style of glows</p> </a> </li> <li> <a href="IMG/numbers-09.jpg"> <img src="IMG/numbers-09.jpg" alt=""> <p>Drips using Photoshop</p> </a> </li> <li> <a href="IMG/numbers-12.jpg"> <img src="IMG/numbers-12.jpg" alt=""> <p>Creating shapes using repition</p> </a> </li> </ul> </section> <footer> <a href="https://twitter.com/id_originals"><img src="IMG/twitter-wrap.png" alt="Twitter Logo" class="social-icon"></a> <a href="https://www.facebook.com/kenzofooks"><img src="IMG/facebook-wrap.png" alt="Facebook Logo" class="social-icon"></a> <p>© 2014 Ryan Fukuhara.</p> </footer> </div> </body> </html>
Robert Komaromi11,926 Points
If your code is simply ...
<!DOCTYPE html> Ryan Fukuhara | Web Design Ryan Fukuhara Web Design Portfolio About Contact Experimentation with colors and textures Photoshop stuff Trying to make 80's style of glows Drips using Photoshop Creating shapes using repition © 2014 Ryan Fukuhara.
.. then yes, there is something wrong with it. You should format it like so ...
<html> <head> </head> <body> <!-- Your content here --> </body> </html>
But I'm assuming that is not actually what your code looks like, in which case, refer to Andrew's answer and use Markdown to correctly display your code.
A 404 error, however, will not be caused by incorrect html syntax. Take a look at the address bar in your web browser; is it pointing to about.html? Ensure there are no typos in your URLs and file names. Also make sure that the URL is a relative URL pointing to about.html (I'm assuming about.html and index.html are in the same directory).
Andrew Molloy37,259 Points
You need to use markdown to post your code here, three back ticks must surround your code ``` and put "html" after the first backticks.
404 would indicate either your file doesn't exist or your link is to the wrong location.
Did you link the about.html page into the menu `
Your file name is about.html?