Jump to content

Wikipedia talk:Advanced template coding

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Redrose64 (talk | contribs) at 09:26, 25 February 2025 (Proper coding of page link requiring escaped characters: no need for external links when normal wikilinks work perfectly well). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

What's the solution for wiki formatting with #if ?

You describe the issue where MediaWiki wiki-formats the clauses inside #if, but you don't say how to solve it! I've got an #if template that needs to generate http links containing semicolons (mw:Template:git file), and it messes up, badly and almost randomly. Is there a solution? -- Skierpage (talk) 20:54, 21 September 2012 (UTC)[reply]

If it is just an address, using &#59; instead of ; will work. Or, if the link always contains git before the semicolon, try adding git inside of #if. — TAKASUGI Shinji (talk) 02:25, 25 January 2013 (UTC)[reply]
This issue came up today here. I found that using %3A URL encoding for the initial colon resolved the problem where using html encoding : produced inconsistent results apparently depending on context. I updated the doc for {{sortname}} to suggest this. Maybe it should be mentioned here, too? — jmcgnh(talk) (contribs) 05:13, 30 September 2022 (UTC)[reply]

...which is a soft redirect to the page of the same title on Meta. Should it be mentioned in the "See also" section? --SoledadKabocha (talk) 18:45, 10 November 2012 (UTC)[reply]

I've been trying to add a hyperlink to an entry within a table on the following page (look for the "The 5th Dimension / Live!!" entry): The_5th_Dimension_discography

The closest I've been able to get is with this code:

! scope="row" | The 5th Dimension / Live!! |

But that just gets me a link with reverse slashes in the URL. The double exclamation marks are a problem, but that was the original album title.

The page I would be linking to is here: The_5th_Dimension_/_Live!!

Pherank (talk) 08:02, 25 February 2025 (UTC)[reply]