Links take staff to another intranet page, a website, a document or an email address. This page also covers anchor links, which jump to a section of the same page.
Write link text that makes sense on its own
Link the words that describe where the link goes, such as “Book annual leave”. Do not use “click here”, “read more” or a bare web address. Screen reader users often move through a page from link to link, so each link has to make sense out of context. If the Govintra accessibility checks are switched on, WordPress warns you about unhelpful link text when you save.
Link to another page on the intranet
- In the editor, select the words you want to turn into a link.
- Select Insert/edit link on the editor toolbar, or press Ctrl + K (Command + K on a Mac).
- Start typing the title of the page. WordPress lists matching intranet content.
- Select the page from the list, then select the blue Apply button.
If the page you want is not in the list, select the cog button, Link options, to search more fully.
Copy page addresses from the live intranet, not from the editing screen. An address that contains wp-admin or preview=true only works for editors, and other staff will see an error.
Link to an external website
Copy the full web address, including https://. Select your link words, select Insert/edit link, paste the address and select Apply.
Govintra adds a small icon after links that go to another website, so you do not need to write “(external link)”.
Open a link in a new tab
Links open in the same tab unless you change them. This is best for most links, because it keeps the browser’s Back button working and does not surprise people using screen readers or phones.
To make one link open in a new tab, select the link, select the pencil button, Edit, then the cog button, Link options, tick Open link in a new tab and select Update. Consider this only where leaving the page would lose someone’s work, such as guidance they need to read while filling in a form.
Link to a document such as a PDF or Word file
- Put the cursor where you want the link.
- Select Add Media, then upload the document or choose it from the Media Library.
- Change the Title to the words you want staff to see, because the title becomes the link text.
- Under Attachment display settings, set Link To to Media File.
- Select Insert into page or Insert into post.
To link words you have already written, open the document in the Media Library, select Copy URL to clipboard, then add the link in the usual way.
Govintra adds a file type icon before links to PDF, Word, Excel and PowerPoint files. It helps to add the type and size to the link text as well, such as “Expenses policy (PDF, 250KB)”.
For a list of downloads on a page, use the Document attachments box under the editor instead. It lists each file with its type and size automatically.
When a document changes, replace the file instead of uploading a new one, so that existing links keep working. See Replace an existing document.
Link to an email address
Select the words or the email address, select Insert/edit link, and type mailto: followed by the address, with no space, such as mailto:hr@example.gov.uk. Select Apply. Govintra adds an envelope icon before email links.
Add an anchor link that jumps to a section of the page
An anchor is an invisible marker in the page. A link to the anchor makes the browser jump to that point. Anchor names must be unique on the page, in lower case, with hyphens instead of spaces, such as how-to-apply.
Before you add anchors by hand, check the page template. The Long page template builds a contents list from your Heading 2 and Heading 3 headings automatically, so it needs no anchors.
Add the anchor
- Put the cursor just before the heading you want to jump to.
- Select the Anchor button on the second row of the editor toolbar. It looks like a bookmark. You can also choose Insert, then Anchor from the menu bar.
- Type the anchor name and select OK. A small anchor marker appears in the editor. Staff do not see it.
- Repeat for each section you want to jump to.
If you cannot see the second row of buttons, select Toolbar Toggle on the first row.
Add an anchor if your editor has no Anchor button
- Select the Text tab of the editor.
- Find the heading, which looks like
<h2>How to apply</h2>. - Add an id to it:
<h2 id="how-to-apply">How to apply</h2>. - Select the Visual tab to carry on editing.
Link to the anchor
A list of links at the top of a long page is the usual place. Select your link words, select Insert/edit link and type a hash sign followed by the anchor name, such as #how-to-apply. To link to the anchor from a different page, put the page address first: /task/claim-expenses/#how-to-apply.
Stop a pasted link turning into a preview card
When a web address sits on a line of its own, WordPress tries to embed it. The address of another intranet page becomes a preview card with the page’s title, image and summary. A YouTube or Vimeo address becomes a video player.
If you want an ordinary link instead, do not paste the address on its own line. Write some link words, select them and add the address with Insert/edit link.
Edit or remove a link
Select the link in the editor. A small box appears. Select the pencil button, Edit, to change the link. To remove the link and keep the words, select Remove link, the broken chain button, in the small box or on the first row of the editor toolbar.
Find broken links
Links break when the page or document they point to is moved or deleted. Administrators can install the Broken Link Checker plugin, which lists broken links across the intranet.
