Lessons

Lesson 3 - Links

dry overwintered hops hanging from a vine

There are two ways to insert a link. The Markdown way is easier, but the HTML route will afford you more control.

Markdown

For a Markdown-style link, you'll wrap your link text in square brackets, followed immediately by the link itself in parentheses, like so:

This is a link to Lee's website.

It's always necessary to include https:// at the start of a link, because if you don't, your browser will think it is a link to somewhere within your site.

By not writing https:// we can link directly to other pages on the site:

This links directly to the "About" page.

It's important to include that leading slash, because that tells the browser that the link is the page /about and not /gallery/lesson-3-links/about.

HTML

You might have noticed if you clicked on the link to my website that it opened in the same tab, not a new tab. Sometimes this isn't what you want. In that case, you can use an HTML-style link.

This is a link to Lee's website that will open in a new tab.

The target="_blank" bit is what makes it open in a new tab.

It's important to make sure that your link text actually describes the link if read as a standalone item. This adds to accessibility as well as SEO. Because of this, you'll want to avoid links that say things like "Read more" or "More info."