Linking: Difference between revisions
Markmcumber (talk | contribs) No edit summary |
Markmcumber (talk | contribs) No edit summary |
||
Line 2: | Line 2: | ||
<br/><br/><br/><br/>'''[[Archives Manual#Linking within the Wiki|Return to the Student Manual]]''' | <br/><br/><br/><br/><br/><br/>'''[[Archives Manual#Linking within the Wiki|Return to the Student Manual]]''' | ||
= Internal Links = | = Internal Links = | ||
Line 58: | Line 58: | ||
'''Instead'''—using the [[Editors|WikiTextEditor]]—add a category tag to the desired category page but with a colon preceding '''Category'''. | '''Instead'''—using the [[Editors|WikiTextEditor]]—add a category tag to the desired category page but with a colon preceding '''Category'''. | ||
<center>'''Example:''' <nowiki>[[:Category:Example]]</nowiki></center><br/> | <center>'''Example:''' <nowiki>[[:Category:Example]]</nowiki></center><br/> | ||
As with any other link, a [[Mark-up Language|pipe]] can be used to represent the link as [[#Linking_via_Alternate_Text|alternate text]]. | As with any other link, a [[Mark-up Language|pipe]] can be used to represent the link as [[#Linking_via_Alternate_Text|alternate text]]. | ||
Line 65: | Line 64: | ||
= Linking to Image Pages = | = Linking to Image Pages = | ||
Contributors will not likely need to link to '''Image Pages''', although instructions on how to do so can be found [[Linking to Image Pages|here]]. | Contributors will not likely need to link to '''Image Pages''', although instructions on how to do so can be found [[Linking to Image Pages|here]]. | ||
= Anchors (Link to a Specific Place on a Page) = | = Anchors (Link to a Specific Place on a Page) = | ||
Line 72: | Line 71: | ||
*This is particularly relevant for larger pages with a lot of content. | *This is particularly relevant for larger pages with a lot of content. | ||
* | *'''WikiTextEditor''' must be used. | ||
*Remember to verify capitalization and spelling of | *Remember to verify the capitalization and spelling of the title of the [[Entries and Pages|destination]] when creating links. | ||
<br/>Some anchors exist naturally within a page. All of the '''Headers''' are automatically anchors and can be easily identified by their presence in the Table of Contents at the top of a given page. '''To link to a header:''' | |||
*Enter the [[Editors|WikiTextEditor]] and start by creating a [[#Internal Links|basic link]] to the destination page. | |||
*A [[Mark-up Language|number sign]] is used to separate the destination entry/page title from the title of the header on that destination page. | |||
<center><br/>'''Example:''' <nowiki>[[Destination title#Header title|alternate text]]</nowiki><br/></center> | |||
The first step should be to establish a basic link from the [[Entries and Pages|origin]] to the [[Entries and Pages|destination]] entry/page. Having successfully saved that change, the contributor will re-enter the Edit section and select the '''WikiTextEditor''', and locate the link that has just been created. | |||
<br/>[[Destination page Destination page#Header title of Destination page]]<br/>[[Destination page#Header title on Destination page|Alternative text]]<br/>'''Example:''' [[Mark's Page#Sneaker Collection|Mark loves sneakers]] | |||
<br/>[[Destination page | |||
The result will be a link that directs the reader to Mark's Page with the specified anchor/header (Sneaker Collection) at the top of the window, with the hyperlinked text <span style="color: rgb(0, 0, 205);"><u>Mark loves sneakers</u></span> will be created on the origin page .</center></div> | The result will be a link that directs the reader to Mark's Page with the specified anchor/header (Sneaker Collection) at the top of the window, with the hyperlinked text <span style="color: rgb(0, 0, 205);"><u>Mark loves sneakers</u></span> will be created on the origin page .</center></div> | ||
<br/>2. Some entries may not be effectively broken up by headers, while some sections might be too long for linking to the header to be an effective solution - do not fear! There is a way to manually create an anchor on a page, but the '''WikiTextEditor''' must be used: | <br/>2. Some entries may not be effectively broken up by headers, while some sections might be too long for linking to the header to be an effective solution - do not fear! There is a way to manually create an anchor on a page, but the '''WikiTextEditor''' must be used: |
Revision as of 14:38, 20 June 2014
Internal Links
An Internal Link is used to direct the user to another page within the UNB wiki. These internal links are the most effective way to establish a web of connections throughout the wiki that enhance readers' experience by increasing accessibility of information.
RichTextEditor
Creating an Internal Link with the RichTextEditor is quick and easy, as MediaWiki provides the Contributor with a field to search the entire wiki for the desired destination page/entry. To generate this field, click the Link icon:
Clicking the link icon will generate a new box in which existing pages can be searched - as long as the contributor knows the title of the destination entry/page. Upon inputting the first few characters the desired destination should appear to be selected, establishing a hyperlink on the origin entry/page.
WikiTextEditor
To create an internal link, enclose the title of the destination entry with double square brackets on either side:
- If the destination entry exists and has been entered correctly an operational link will be created.
- Remember that Mediawiki is case sensitive - the first thing that the contributor should check for if a link does not work is the spelling and capitalization of the destination entry within the WikiTextEditor code.
- If the destination entry does not exist, the hyperlink created will connect to a new page upon which an entry can be created, either immediately or in the future.
- The practice of creating links to non-existent pages for future creation is called lazy linking, which can be an effective way to communicate to future contributors the pages that need to be created and the future direction of the wiki.
Linking via Alternate Text
Sometimes the exact title of a page is not ideal to insert into a sentence and an alternate text would better serve the entry/page. Instead, best practice is to present the hyperlink as text that flows within the entry.
It is in the wiki's interest to establish a link to the Literary and Debating Society page, but inserting this title would obstruct the flow of the sentence.
RichTextEditor
Using the RichTextEditor, simply write the sentence and highlight the text intended to be presented as hyperlink, and complete the process as outlined in the section above by clicking the link icon and selecting the destination entry/page.
WikiTextEditor
To establish a link using alternate text with the WikiTextEditor, a pipe (or vertical bar)— | —must be placed after the title of the destination entry/page, followed by the desired alternate text and enclosed between double square brackets:
[[Literary and Debating Society|Debating]] has long been a popular extracurricular activity at UNB.
(Result:) Debating has long been a popular extracurricular activity at UNB.
Lazy Linking
Lazy Linking is the process of actively creating links to non-existent entries/pages with the intention of creating them—or having someone else create them—in the future. It is an effective way to map out the future of the wiki's development without deviating from the task at hand to establish a new entry/page (the perpetual nature of this deviation could be infinite and result in an infinite number of unfinished pages - don't mind the dramatics).
Hyperlinks to non-existent entries/pages will appear red - clicking a red hyperlink will allow the contributor to edit this non-existent entry/page.
http://unbhistory.lib.unb.ca/index.php/Special:WantedPages
External Links
Student contributors will likely not need to link to external sites, but if the rare occasion were to arise there are several ways to create an external link.
Linking to Category Pages
Linking to a category page can be useful as well.
To link to a category page one must use WikiTextEditor. The RichTextEditor does not appear to allow linking to category pages.
Instead—using the WikiTextEditor—add a category tag to the desired category page but with a colon preceding Category.
As with any other link, a pipe can be used to represent the link as alternate text.
Linking to Image Pages
Contributors will not likely need to link to Image Pages, although instructions on how to do so can be found here.
Anchors (Link to a Specific Place on a Page)
When referring to specific information, it may prove useful to know how to link to a specific place on an entry/page. This is achieved by linking to an anchor.
- This is particularly relevant for larger pages with a lot of content.
- WikiTextEditor must be used.
- Remember to verify the capitalization and spelling of the title of the destination when creating links.
Some anchors exist naturally within a page. All of the Headers are automatically anchors and can be easily identified by their presence in the Table of Contents at the top of a given page. To link to a header:
- Enter the WikiTextEditor and start by creating a basic link to the destination page.
- A number sign is used to separate the destination entry/page title from the title of the header on that destination page.
Example: [[Destination title#Header title|alternate text]]
The first step should be to establish a basic link from the origin to the destination entry/page. Having successfully saved that change, the contributor will re-enter the Edit section and select the WikiTextEditor, and locate the link that has just been created.
[[Destination page Destination page#Header title of Destination page]]
[[Destination page#Header title on Destination page|Alternative text]]
Example: [[Mark's Page#Sneaker Collection|Mark loves sneakers]]
The result will be a link that directs the reader to Mark's Page with the specified anchor/header (Sneaker Collection) at the top of the window, with the hyperlinked text Mark loves sneakers will be created on the origin page .</center>
2. Some entries may not be effectively broken up by headers, while some sections might be too long for linking to the header to be an effective solution - do not fear! There is a way to manually create an anchor on a page, but the WikiTextEditor must be used:
<span id="Anchor_name">Text can be inserted here (although the absence of text will produce an invisible anchor)<span>
Spaces cannot be used in the "Anchor_name", so make use of _'s, and remember to use quotation marks.
Having created this anchor, the next step is to link to it. This process is identical to linking to headers as described above: