<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://moasspedia.org/w/index.php?action=history&amp;feed=atom&amp;title=Template%3AUrltowiki%2Fdoc</id>
	<title>Template:Urltowiki/doc - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://moasspedia.org/w/index.php?action=history&amp;feed=atom&amp;title=Template%3AUrltowiki%2Fdoc"/>
	<link rel="alternate" type="text/html" href="https://moasspedia.org/w/index.php?title=Template:Urltowiki/doc&amp;action=history"/>
	<updated>2026-04-14T03:07:13Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.37.2</generator>
	<entry>
		<id>https://moasspedia.org/w/index.php?title=Template:Urltowiki/doc&amp;diff=34717&amp;oldid=prev</id>
		<title>Wikipedia&gt;BarrelProof: /* Known limitations */ Misspelling</title>
		<link rel="alternate" type="text/html" href="https://moasspedia.org/w/index.php?title=Template:Urltowiki/doc&amp;diff=34717&amp;oldid=prev"/>
		<updated>2021-11-22T01:47:06Z</updated>

		<summary type="html">&lt;p&gt;&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;Known limitations: &lt;/span&gt; Misspelling&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Documentation subpage}}&lt;br /&gt;
{{template shortcut|url2wiki|u2w}}&lt;br /&gt;
{{lua|Module:Urltowiki}}&lt;br /&gt;
&amp;lt;!-- Categories go at the bottom of this page and interwikis go in Wikidata. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This template takes a wiki URL and outputs the equivalent wikilink, with optional display text. It is useful for quickly creating properly formatted wikilinks to talk page sections or external wikis. It accepts URLs from most Wikimedia wikis. The template should usually be [[WP:SUBST|substituted]], but will work with [[WP:TRANSCLUSION|transclusion]] as well.&lt;br /&gt;
&lt;br /&gt;
If given a partial URL (without the protocol and the host name) the template will remove any underlines and decode [[percent-encoded]] characters. If given a valid URL that is not recognised as a Wikimedia wiki, it will output the URL unlinked. See [[#Known limitations|below]] for how to add new wikis.&lt;br /&gt;
&lt;br /&gt;
The shortcut {{tld|u2w}} is available.&lt;br /&gt;
&lt;br /&gt;
A similar URL-to-wikitext transformation can be done directly in the edit window using the [[User:Js/urldecoder]] user script.&lt;br /&gt;
&lt;br /&gt;
== Usage ==&lt;br /&gt;
&lt;br /&gt;
;Quick usage&lt;br /&gt;
:CAUTION: This syntax will not work if the URL contains &amp;quot;=&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;{{subst:u2w|&amp;lt;!-- URL --&amp;gt;|&amp;lt;!-- display text --&amp;gt;}}&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;Basic usage&lt;br /&gt;
:The following will work for all URLs.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;{{subst:u2w|1=&amp;lt;!-- URL --&amp;gt;|2=&amp;lt;!-- display text --&amp;gt;}}&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;{{subst:u2w|url=&amp;lt;!-- URL --&amp;gt;|display=&amp;lt;!-- display text --&amp;gt;}}&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;All parameters&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;{{subst:u2w&lt;br /&gt;
| url        = &lt;br /&gt;
| display    = &lt;br /&gt;
| link       = &lt;br /&gt;
| section    = &lt;br /&gt;
| colontrick = &lt;br /&gt;
| error      = &lt;br /&gt;
}}&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Parameters ==&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;url&amp;#039;&amp;#039;&amp;#039; - the URL you wish to be converted into wikitext. This parameter is required. You can also use the first positional parameter for the URL, but this will not work if the URL contains an equals sign.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;display&amp;#039;&amp;#039;&amp;#039; - the text you would like to be displayed, if not the interwiki link itself. This is equivalent to the text that comes after the pipe in a piped link. You can also use the second positional parameter for the display text, but this will only work if the first positional parameter is also present. Therefore, if you use this for the display value there must be no equals sign in the URL.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;link&amp;#039;&amp;#039;&amp;#039; - if this is set to &amp;quot;no&amp;quot;, the template will not link the interwiki link, and will not display the display text.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;section&amp;#039;&amp;#039;&amp;#039; - if this is set to &amp;quot;no&amp;quot;, no section links will be produced.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;colontrick&amp;#039;&amp;#039;&amp;#039; - if this is set to &amp;quot;no&amp;quot; the template will not use the [[Help:Colon trick|colon trick]] for files and category pages. Note that if {{para|link|no}} then the colon trick will not be used anyway - this is necessitated by a [[phab:T14974|longstanding bug]] in Mediawiki.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;error&amp;#039;&amp;#039;&amp;#039; - if this is set to &amp;quot;no&amp;quot; the template will return nothing instead of producing error messages if there is missing or invalid input.&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
&lt;br /&gt;
{| class = &amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Code&lt;br /&gt;
! Result&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{subst:u2w|error=no}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{u2w|error=no}}&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{subst:u2w|url=https://en.wikipedia.org/wiki/Pearl_Jam}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{u2w|url=https://en.wikipedia.org/wiki/Pearl_Jam}}&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{subst:u2w|url=https://en.wikipedia.org/w/index.php?title=Pearl_Jam&amp;amp;action=history}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{u2w|url=https://en.wikipedia.org/w/index.php?title=Pearl_Jam&amp;amp;action=history}}&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{subst:u2w|url=https://en.wikipedia.org/wiki/Wikipedia:Village_pump_%28policy%29/Archive_102#Using_.7B.7BComment.7D.7D_on_articles}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{u2w|url=https://en.wikipedia.org/wiki/Wikipedia:Village_pump_%28policy%29/Archive_102#Using_.7B.7BComment.7D.7D_on_articles}}&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{subst:u2w|url=https://en.wikipedia.org/wiki/Wikipedia:Village_pump_%28policy%29/Archive_102#Using_.7B.7BComment.7D.7D_on_articles|display=the village pump}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{u2w|url=https://en.wikipedia.org/wiki/Wikipedia:Village_pump_%28policy%29/Archive_102#Using_.7B.7BComment.7D.7D_on_articles|display=the village pump}}&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{subst:u2w|url=https://es.wikivoyage.org/wiki/Bogot%C3%A1#En_avi.C3.B3n}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{u2w|url=https://es.wikivoyage.org/wiki/Bogot%C3%A1#En_avi.C3.B3n}}&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{subst:u2w|url=https://es.wikivoyage.org/wiki/Bogot%C3%A1#En_avi.C3.B3n|link=no}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{u2w|url=https://es.wikivoyage.org/wiki/Bogot%C3%A1#En_avi.C3.B3n|link=no}}&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{subst:u2w|url=https://es.wikivoyage.org/wiki/Bogot%C3%A1#En_avi.C3.B3n|display=Bogota by plane}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{u2w|url=https://es.wikivoyage.org/wiki/Bogot%C3%A1#En_avi.C3.B3n|display=Bogota by plane}}&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{subst:u2w|url=https://en.wikipedia.org/wiki/Category:Wikipedians}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{u2w|url=https://en.wikipedia.org/wiki/Category:Wikipedians}}&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{subst:u2w|url=https://en.wikipedia.org/wiki/Category:Wikipedians|colontrick=no}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
| &amp;lt;!-- {{u2w|url=https://en.wikipedia.org/wiki/Category:Wikipedians|colontrick=no}} We&amp;#039;ll just pretend we&amp;#039;re outputting this to avoid categorising the page --&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{subst:u2w|url=https://en.wikipedia.org/wiki/Wikipedia:Village_pump_%28policy%29/Archive_102#Using_.7B.7BComment.7D.7D_on_articles|section=no}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{u2w|url=https://en.wikipedia.org/wiki/Wikipedia:Village_pump_%28policy%29/Archive_102#Using_.7B.7BComment.7D.7D_on_articles|section=no}}&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Known limitations ==&lt;br /&gt;
&lt;br /&gt;
This template will not work correctly if the original section name contains anything that looks [[percent-encoded]]. This usually means a period followed by two characters that could be [[hexadecimal]]. For example, the code &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{subst:u2w|url=https://en.wikipedia.org/wiki/Wikipedia:Sandbox#Pi_equals_3.14}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; produces {{u2w|url=https://en.wikipedia.org/wiki/Wikipedia:Sandbox#Pi_equals_3.14}}. To work around this you can set {{para|section|no}} and {{para|link|no}}, and add the link and the proper section name yourself. However, bear in mind that the actual link will still work properly even if it is displayed incorrectly, so it is not necessary to use the workaround if you also set the {{para|display}} parameter.&lt;br /&gt;
&lt;br /&gt;
Additionally, some Wikimedia sites may not be supported yet. If you come across a site that isn&amp;#039;t supported, please consider adding it to [[Module:InterwikiTable]], as then it will work for all users.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
* [[User:Js/urldecoder]], a user script that does a similar conversion directly in the edit window&lt;br /&gt;
* [[Template:Url to diff]], for converting diff URLs to use the {{tl|diff}} template&lt;br /&gt;
&lt;br /&gt;
&amp;lt;includeonly&amp;gt;{{Sandbox other||&lt;br /&gt;
&amp;lt;!-- Categories go here, and interwikis go in Wikidata --&amp;gt;&lt;br /&gt;
[[Category:Internal link templates]]&lt;br /&gt;
}}&amp;lt;/includeonly&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikipedia&gt;BarrelProof</name></author>
	</entry>
</feed>