User:Js/urldecoder

urlDecoder button

 [http://meta.wikime…
 [[meta:Page]]

urldecoder
Browsers *
Skins *
Code urldecoder.js
Released April 24, 2009; 15 years ago (2009-04-24)
Updated September 22, 2024; 0 days ago (2024-09-22)
Developer   AlexSm

urldecoder is a userscript for easy pasting of links into wikicode.

How to use it:

  • paste any URL
  • (if desired) type a blank space and then the link name (what will be displayed):
http://de.wikipedia.orgview_html.php?sq=&lang=&q=Ding this page|
  • select (highlight) the text you want decoded
  • press the urlDecoder button button to get this:
[[:de:Ding|this page]]

The script will:

  • automatically add brackets to form an external link,
  • make it an internal link (if possible) using most Interwikimedia prefixes,
  • percent-decode URL: a %26 ba & b
    which is mostly useful in non-Latin wikis where most URLs look like %D1%EB%F3%E6…
  • convert (now outdated) secure.wikimedia.org links to normal.

The script will simplify all URLs inside the text you select; it is not limited to processing a single url.