Sunday, January 19, 2014

Links Links Links!

You can probably guess what today's post is about... Yup, you guessed it! Links!

You use the <a> tag to create links. For example, if you wanted to put a link on your website so that when people click on the link, it takes them to google, you add this:

<a href="http://www.google.com">Go to Google</a>

If you want to link to something on your own server, then you use the path it takes to get there, according to the webpage. For example, if you want to link from the index.html to about.html, and about.html is in the same folder as your index.html, you add this to your index.html:

<a href="about.html">About Me</a>

If you want to link from index.html to post5.html which is in the posts folder, and the posts folder is in the same folder as your index.html, you add this to your index.html:

<a href="posts/post5.html">Post #5</a>

Get it?

No comments:

Post a Comment