Pointing readers to a specific spot on a new post, a previous post or a WordPress page can be an efficient way to guide readers to see specific content without having them scroll down the page or search the text. An anchor fills the bill.
An anchor is a tiny bit of code that you insert at a specific spot on your post or page. When you place an anchor on your post or page, you can link to it from any place on the post or page or any other post or page. Try this: Click Jump Me Down and see how it works.
Here’s a step-by-step guide to using an anchor:
- Find the location on your post/page where you want the reader to land.
- Put your cursor next to a word somewhere down the page that will be your anchor. This is usually the first word in the content being linked to.
- In the upper right-hand corner of your post or page edit window, click on the Text tab. This will change your page from a visual format to a text or coding format. Don’t get overwhelmed by all the computer gibberish. We’re just adding a tiny piece of code.
- To the left of your anchor word paste in this code:<p id=”jumpdown”/p>
You can use any word to replace “jumpdown”.
- Click the Visual tab next to the Text tab and scroll up in your edit window and type some text that will be the link to the anchor. This could be something as simple as “Click Here” or “espaňol”. Click the Text tab again, find your link to the anchor and paste this code next to it:
- Now cut your link word(s) (“Click Here” or “espaňol”) and paste it between the > < symbols so the link looks like this:
<a href=”#jumpdown”> Click Here </a>
Notice that the anchor and the link use the exact same word: jumpdown. The words have to match so the link knows where to find the anchor.
- Test it out by saving your post/page as a draft then click on Preview.
And here you are . . . right down here where there might be some links, instructions or a Spanish translation.
Click to Jump back to the top.
That’s all there is to linking to an anchor when both the link and anchor are on the same page. But how does it work if you are linking from one post/page to another or even one WordPress site to another?
The process is almost the same with this one small difference:
The anchor remains exactly the same, but the link needs to know on which page or post the anchor resides. So the link, instead of this – <a href=”#jumpdown”> Click Here </a>- would now look like this:
<a href=”http://blogs.bethel.k12.or.us/yoursitename/?p=5570/#jumpdown”>Click Here</a>
Where the entire URL for the page is part of the link.
Prairie Mountain is using anchors to make is a single click for Spanish speaking parents to read translated blog posts.