GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Main page
  • Get MediaWiki
  • Get extensions
  • Tech blog
  • Contribute
  • User help
  • FAQ
  • Technical manual
  • Support desk
  • Communication
  • Developer portal
  • Code statistics
  • Community portal
  • Recent changes

This view

  • Original page
  • New address

GeezerVison is showing www.mediawiki.org — Help:Self link - MediaWiki

PD Note: When you edit this page, you agree to release your contribution under the CC0. See Public Domain Help Pages for more info. PD

A self link is a wikilink which targets the page where it is placed. To avoid any confusion, a self-link is not clickable: the text is only bolded (but still represented as an ‎<a>…‎</a> tag).[1]

Examples:

  • [[Help:Self link]] gives Help:Self link
  • [[Help:Self link]]abc gives Help:Self linkabc
  • [[Help:Self link|abc]] gives abc

If the preference to underline links is set, self links are still underlined, unless this is explicitly disabled by the following CSS:

.mw-selflink { text-decoration: none !important; }

Similarly, bolding can also be explicitly disabled if desired:

.mw-selflink { font-weight: normal !important; }

Utility

In templates transcluded on several pages (typically navigational templates), a link can usefully become a self link when the template is transcluded on the link target page. This avoids the reader believing they will see another page when clicking on it.

Clickable self links

Some kinds of self links are clickable, because they are not a simple internal link with direct target.

Full URL

If you use external link syntax, providing the full URL of the page, the link is always clickable.

E.g. [//www.mediawiki.org/wiki/Help:Self_link abc] gives abc

Link to self redirection

If you link to a page which redirects to the current page, the link remains clickable and not bolded.

Link to a local section

Main page: Help page about links, anchor section

If the target contains a fragment, even if the link targets the current section, it remains clickable and not bolded.

E.g. [[Help:Self link#Link to a local section]] gives Help:Self link#Link to a local section.

References

  1. ↑ From 2017 change (developer task).
Retrieved from "https://www.mediawiki.org/w/index.php?title=Help:Self_link&oldid=8099027"
Categories:
  • Help
  • Link
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.