Template talk:Overpassapi

From OpenStreetMap Wiki
Jump to: navigation, search

"External" links to Wiki-internal pages

Why is [{{FULLURL:Special:Target Page|namespace=0}} Link text] used for the "more:" links, thereby creating "external" links, even though the target pages are (Special:) pages of this very Wiki?
--Das-g (talk) 11:31, 29 May 2017 (UTC)

It is used for specifying the namespace to search for (which has no equivalent using only a Special: wikilink which searches in the incorrect namespace). Namespace 0 is used for English, 7 other namespaces (with even numbers 200 and above) are used for DE, ES, FR, IT, JA, NL, RU; all other languages are using namespace 0 (the same an English, but using language code prefixes in their page names). These namespace numbers are determined by {{LangNS}}. There's no way to use something else than namespace numbers (the namespace prefixes are not supported by the "Special:" query page). There's no other way to specify this parameter with a classic internal wikilink.
  • This is also true when you want to create an "edit page" link, or "purge page" link, you use "FULLURL:" as well to pass additional parameters not available with the standard internal wikilinks (which only support a default "action=view" for browsing standard pages).
  • This is also true when you want to pass additional parameters with Special:PrefixIndex (where you also need a namespace number parameter to add a filter instead of listing only pages in the default namespace 0, or listing other pages in "Template:", "File:", or "Category:").
Don't worry, FULLURL will still generate a correct internal link, with the correct protocol and domain name, for the specified Pagename given exactly like in internal link (it will be properly URL-encoded when needed). — Verdy_p (talk) 16:59, 29 May 2017 (UTC)
Well, it works, sure, but it displays the https://wiki.openstreetmap.org//w/skins/Vector/images/external-link-ltr-icon.png?325de icon that is rather misleading if the link keeps you on the same wiki.
--Das-g (talk) 09:40, 2 June 2017 (UTC)
It's not a standard wiki page, but actually a query, these links are for special use but only to complete the links displayed before. If you want, I can suppress the blue arrow icons easily (done!). — Verdy_p (talk) 15:09, 2 June 2017 (UTC)
Thanks, looks good!
--Das-g (talk) 21:55, 3 June 2017 (UTC)