Template:Diff/translator: Difference between revisions
From Black Cat Studios
Jump to navigationJump to search
(Created page with "<includeonly><nowiki>{{</nowiki>Diff||{{#invoke:String|sub |{{#invoke:String|match|{{{url|}}}|diff{{=}}%d+|nomatch=diff{{=}}next}}|i=6 }}|{{#invoke:String|sub |{{#invoke:String|match|{{{url|}}}|oldid{{=}}%d+}}|i=7 }}|{{{1|}}}{{#ifeq:{{#invoke:String|str_find|{{{url|}}}|diffonly{{=}}1}}|-1|||diffonly=yes}}<nowiki>}}</nowiki></includeonly><noinclude>{{documentation}}</noinclude>") |
(No difference)
|
Latest revision as of 16:31, 19 June 2023
Helper subtemplate
- Syntax
- {{Diff/translator
|label |url=diff URL}}
In order to make the {{Diff}} template simpler to use this helper subtemplate is available, to be used only in the preview window.
For instance, imagine you want to refer to the following diff URL: https://en.wikipedia.org/w/index.php?title=Main_Page&diff=139993&oldid=139992&diffonly=1; you only need to transcribe that URL in this subtemplate and produce a preview, without saving the page:
{{Diff/translator|Sic exorsi sumus|url=https://en.wikipedia.org/w/index.php?title=Main_Page&diff=139993&oldid=139992&diffonly=1}}- ↳
{{Diff||139993|139992|Sic exorsi sumus|diffonly=yes}}
- ↳
Now copy the code generated ({{Diff||139993|139992|Sic exorsi sumus|diffonly=yes}} into the edit window where {{Diff/translator}} was and publish the page.