Sikau

HTML · Day 4 · about 25 min

Links

The "hyper" in hypertext.

What makes it a web

Links connect pages into a web. The <a> (anchor) element links to other sites, other pages of yours, a section of the same page, an email address or a phone number.

The a element

  • Absolute URLs include the site: https://…. Relative URLs point within your site: /about.html, menu.html.
  • #id jumps to the element with that id on the page.
  • target="_blank" opens a new tab — add rel="noopener" for safety, and use it sparingly.

The rest of this lesson

  • Anatomy of a URLexplain
  • Special links and safe new tabsexplain
  • Where does it go?predict
  • Complete the linksfill
  • Your turnwrite code
  • Badge quizquiz
  • What you learnedrecap

Continue this lesson free — run real code in your browser

Continue with Google

See all 17 lessons of HTML