Anchors & Attributes

Create links on your web page!

*Tip: Try having a notepad and writing down what you learn!

Download Notes

Now we can create elements that actually help link our pages in our website, or provide links to other websites! The information called "attributes" must be written in the opening tag.

Main Points:

  1. An "anchor" element is written like a normal text element
  2. However an anchor requires an "attribute" to work, which is written in the opening tag.
  3. "href" stands for "Hyper-Link Reference" and tells us where this anchor will take us.
  4. "href" and "target" are both attributes and must be written in the opening tag.
// This will take us to, but will replace our website
<a href="">Take me to Apple</a>

//This will take us to in a new tab on our browser
<a href="">Take me to YouTube</a>

**If you havent set up your website yet please watch the first videos under "Setting Up".

Sign Up