Difference between revisions of "Template:~Link"

From Maths
Jump to: navigation, search
(Adding replace1 named parameter, which will use the first parameter for the link, but replace it for the place where the first parameter goes in the display of the link)
m (Alec moved page Template:Link to Template:~Link: For update documented on the page)
 
(5 intermediate revisions by the same user not shown)
Line 17: Line 17:
 
** {{C|<nowiki>{{link|pupp|example|y|ies}}</nowiki>}} for a link to the {{C|puppy (example)}} page, rendered as {{C|puppies}}.
 
** {{C|<nowiki>{{link|pupp|example|y|ies}}</nowiki>}} for a link to the {{C|puppy (example)}} page, rendered as {{C|puppies}}.
 
* As of 7<sup>th</sup> of September 2017 you can use interwiki links, using the w or wiki parameter
 
* As of 7<sup>th</sup> of September 2017 you can use interwiki links, using the w or wiki parameter
 +
* As of 31<sup>st</sup> of December 2017 (@1916) you can now use {{C|1=replace1=X}} so {{C|<nowiki>{{link|X|replace1=Z|...}}</nowiki>}} renders as {{C|<nowiki>[[X...|Z...]]</nowiki>}}
 +
** '''UPDATE PLAN:''' (required as it's used in 225 pages at time of writing)
 +
**# Test that a template page being a redirect will forward parameters first
 +
**#* This way we can leave a redirect behind for the move in step 2, thus not breaking everything
 +
**# Move Template:Link to template {{strike|_Link}} - {{C|~Link}}
 +
**# Re-write template:Link to forward parameters initially
 +
**# TEST IT WORKS THUS FAR
 +
**# ALTER template:link to forward with replace1 set with a list index of sorts, using [[Template data:Link substitutions]]'s [[Template data:Link substitutions/List|/List]]
 +
** '''STATUS:'''
 +
*** NOT YET DONE [[User:Alec|Alec]] ([[User talk:Alec|talk]]) 19:25, 31 December 2017 (UTC)
 +
*** Redirect test done (see: [[User:Alec/Template redirect test]]) [[User:Alec|Alec]] ([[User talk:Alec|talk]]) 19:32, 31 December 2017 (UTC)
 +
*** Moving to [[Template:~Link]] - will leave redirect behind. [[User:Alec|Alec]] ([[User talk:Alec|talk]]) 19:37, 31 December 2017 (UTC)
 
</noinclude>
 
</noinclude>

Latest revision as of 19:38, 31 December 2017


Use: {{link|homomorphism|group|ns=optionalns}} to get a link homomorphism to the optionalns:homomorphism (group) page.

  • As of 10th of September 2016, you can now use the Template:Plural syntax, eg:
    • {{link|variable symbol|FOL|s}} for a link as usual, but displayed as variable symbols and
    • {{link|pupp|example|y|ies}} for a link to the puppy (example) page, rendered as puppies.
  • As of 7th of September 2017 you can use interwiki links, using the w or wiki parameter
  • As of 31st of December 2017 (@1916) you can now use replace1=X so {{link|X|replace1=Z|...}} renders as [[X...|Z...]]
    • UPDATE PLAN: (required as it's used in 225 pages at time of writing)
      1. Test that a template page being a redirect will forward parameters first
        • This way we can leave a redirect behind for the move in step 2, thus not breaking everything
      2. Move Template:Link to template _Link - ~Link
      3. Re-write template:Link to forward parameters initially
      4. TEST IT WORKS THUS FAR
      5. ALTER template:link to forward with replace1 set with a list index of sorts, using Template data:Link substitutions's /List
    • STATUS: