Module talk:Footnotes/anchor id list: Difference between revisions

Content deleted Content added
No edit summary
ce
 
(8 intermediate revisions by 3 users not shown)
Line 5:
There has always been a problem with the {{tlx|harv}} and {{tlx|sfn}} families of templates: except that every link that is created by these templates is tested at creation, editors don't know if the link works. A remedy for that has been user-scripts like [[User:Ucucha/HarvErrors]]. But, not all editors use that script so broken harv links can go undetected for a long time. At the moment, there is [[Wikipedia:Bots/Requests_for_approval/AntiCompositeBot|prospective bot]] that would mark broken-link harv templates by adding {{tlx|broken footnote}} after the broken-link harv template.
 
I have another possible solution. I have created a [[Module:Sandbox/trappist the monk/harv link test|lua module]] that extracts reference linking data from cs1|2 and vcite templates. I have modified [[Module:Footnotes/sandbox]] to use the extracted data to determine if:
:the harv template does not have a matching citation template
:more than one citation template matches the harv template
Line 269:
| <code><nowiki>{{Harvard citation no brackets/sandbox|''Magazine Title''|2020}}</nowiki></code> || {{Harvard citation no brackets/sandbox|''Magazine Title''|2020}}
|-
! colspan="2" | {{tlf|harvid}} <!-- harvid replaced with sfnref/sandbox because that calls non-sandbox versions of module:footnotes -->
|-
| <code><nowiki>{{Cite book |title=Title |ref={{SfnRef/sandboxharvid|Blue|2020}}}}</nowiki></code> || {{Cite book |title=Title |ref={{SfnRef/sandboxharvid|Blue|2020}}}}
|-
! colspan="2" | {{tlf|harvid}} <!-- harvid replaced with sfnref/sandbox because that calls non-sandbox versions of module:footnotes -->
|-
| <code><nowiki>{{Cite book |title=Title |ref={{SfnRef/sandboxharvid|Blue|Red|2020}}}}</nowiki></code> || {{Cite book |title=Title |ref={{SfnRef/sandboxharvid|Blue|Red|2020}}}}
|-
! colspan="2" | {{tlf|sfnref}}
|-
| <code><nowiki>{{Cite book |title=Title |ref={{SfnRef/sandboxsfnref|Blue|Red|Black|2020}}}}</nowiki></code> || {{Cite book |title=Title |ref={{SfnRef/sandboxsfnref|Blue|Red|Black|2020}}}}
|-
! colspan="2" | {{tlf|SfnRef}}
|-
| <code><nowiki>{{Cite book |title=Title |ref={{SfnRef/sandbox|Blue|Red|Black|Black|2020}}}}</nowiki></code> || {{Cite book |title=Title |ref={{SfnRef/sandbox|Blue|Red|Black|Black|2020}}}}
|-
! colspan="2" | {{tlf|SfnRef}} – magazine title
|-
| <code><nowiki>{{Cite book |title=Title |ref={{SfnRef/sandbox|''Magazine Title''|2020}}}}</nowiki></code> || {{Cite book |title=Title |ref={{SfnRef/sandbox|''Magazine Title''|2020}}}}
|-
|}
Line 511:
|-
| <code><nowiki>{{Cite book |date={{ISOtoMOS|2020-03-05}} |last=Gray |last2=White |title=Title |ref=harv}}</nowiki></code> || {{Cite book |date={{ISOtoMOS|2020-03-05}} |last=Gray |last2=White |title=Title |ref=harv}}
|}
 
==cite LSA==
{| class="wikitable" width="100%"
|+{{tl|cite LSA}}
!template !! rendering
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|White|2020}}</nowiki></code> || {{Harvard citation no brackets/sandbox|White|2020}}
|-
! colspan="2" | CITEREF uses {{pipe}}last= and {{pipe}}year= always; {{pipe}}ref= not supported
|-
| <code><nowiki>{{cite LSA |year=2020 |last=White |first=First |title=Title}}</nowiki></code> || {{cite LSA |year=2020 |last=White |first=First |title=Title}}
|}
 
== vcite templates ==
 
{| class="wikitable" width="100%"
|+vcite templates
!template !! rendering
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|White|Black|2020|ref=WhiteBlack2020}}</nowiki></code> || {{Harvard citation no brackets/sandbox|White|Black|2020|ref=WhiteBlack2020}}
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|White|Brown|2020}}</nowiki></code> || {{Harvard citation no brackets/sandbox|White|Brown|2020}}
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|White|Red|2020|ref=WhiteRed2020}}</nowiki></code> || {{Harvard citation no brackets/sandbox|White|Red|2020|ref=WhiteRed2020}}
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|White|Yellow|2020}}</nowiki></code> || {{Harvard citation no brackets/sandbox|White|Yellow|2020}}
|-
! colspan="2" | using {{pipe}}ref=
|-
| <code><nowiki>{{vcite book |year=2020 |author=White, Black |title=Title |ref=WhiteBlack2020}}</nowiki></code> || {{vcite book |year=2020 |author=White, Black |title=Title |ref=WhiteBlack2020}}
|-
! colspan="2" | using {{pipe}}harvid= (makes CITEREF...)
|-
| <code><nowiki>{{vancite book |year=2020 |author=White, Brown |title=Title |harvid=WhiteBrown2020}}</nowiki></code> || {{vancite book |year=2020 |author=White, Brown |title=Title |harvid=WhiteBrown2020}}
|-
! colspan="2" | using {{pipe}}ref= and {{pipe}}harvid=
|-
| <code><nowiki>{{vcite book |year=2020 |author=White, Red |title=Title |ref=WhiteRef2020 |harvid=WhiteOrange2020}}</nowiki></code> || {{vcite book |year=2020 |author=White, Red |title=Title |ref=WhiteRed2020 |harvid=WhiteOrange2020}}
|-
! colspan="2" | using {{pipe}}ref={{tl|sfnref}}
|-
| <code><nowiki>{{vcite book |year=2020 |author=White, Black |title=Title |ref={{SfnRef/sandbox|White|Yellow|2020}}}}</nowiki></code> || {{vcite book |year=2020 |author=White, Black |title=Title |ref={{SfnRef/sandbox|White|Yellow|2020}}}}
|}
 
Line 606 ⟶ 563:
| <code><nowiki>{{Harvard citation no brackets/sandbox|Anon.|n.d.(a)}}</nowiki></code> || {{Harvard citation no brackets/sandbox|Anon.|n.d.(a)}}
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|Atwood|2003|ref=Reference-{{SfnRef/sandboxsfnref|Atwood|2003}}}}</nowiki></code> || {{Harvard citation no brackets/sandbox|Atwood|2003|ref=Reference-{{SfnRef/sandboxsfnref|Atwood|2003}}}}
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|Atwood|2003}}</nowiki></code> || {{Harvard citation no brackets/sandbox|Atwood|2003}}
Line 616 ⟶ 573:
! colspan="2" | {{pipe}}ref=
|-
| <code><nowiki>{{wikicite|ref={{SfnRef/sandboxsfnref|Anon.|n.d.(a)}}|reference=Anon. n.d.(a) "[http://www.english-heritage.org.uk/discover/blue-plaques/search/bartok-bela-1881-1945 Bartók, Béla (1881–1945) Plaque erected in 1997 by English Heritage at 7 Sydney Place, South Kensington, London SW7 3NL, Royal Borough of Kensington and Chelsea]". English Heritage website (Accessed 19 October 2012).}}</nowiki></code> || {{wikicite|ref={{SfnRef/sandboxsfnref|Anon.|n.d.(a)}}|reference=Anon. n.d.(a) "[http://www.english-heritage.org.uk/discover/blue-plaques/search/bartok-bela-1881-1945 Bartók, Béla (1881–1945) Plaque erected in 1997 by English Heritage at 7 Sydney Place, South Kensington, London SW7 3NL, Royal Borough of Kensington and Chelsea]". English Heritage website (Accessed 19 October 2012).}}
|-
! colspan="2" | {{pipe}}id=sfnref
|-
|<code><nowiki>{{wikicite | id = {{SfnRef/sandboxsfnref|Atwood|2003}} | reference = Atwood, Margaret (2003). ''Oryx and Crake'', Toronto: McClelland & Stewart. {{ISBN|978-0-7710-0868-9}}. }}</nowiki></code> || {{wikicite | id = {{SfnRef/sandboxsfnref|Atwood|2003}} | reference = Atwood, Margaret (2003). ''Oryx and Crake'', Toronto: McClelland & Stewart. {{ISBN|978-0-7710-0868-9}}. }}
|-
! colspan="2" | {{pipe}}ref=sfnref
|-
|<code><nowiki>{{wikicite | ref = {{SfnRef/sandboxsfnref|Atwood|2003}} | reference = Atwood, Margaret (2003). ''Oryx and Crake'', Toronto: McClelland & Stewart. {{ISBN|978-0-7710-0868-9}}. }}</nowiki></code> || {{wikicite | ref = {{SfnRef/sandboxsfnref|Atwood|2003}} | reference = Atwood, Margaret (2003). ''Oryx and Crake'', Toronto: McClelland & Stewart. {{ISBN|978-0-7710-0868-9}}. }}
|}
 
Line 643 ⟶ 600:
! colspan="2" | multiple anchors
|-
| <code><nowiki>{{anchor|{{SfnRef/sandboxsfnref|Blue|Yellow|2018}}|plain text|CITEREFciteref2030|{{SfnRef/sandboxsfnref|Yellow|Blue|2019}}}}</nowiki></code> || {{anchor|{{SfnRef/sandboxsfnref|Blue|Yellow|2018}}|plain text|CITEREFciteref2030|{{SfnRef/sandboxsfnref|Yellow|Blue|2019}}}} anchors are here
|}
 
Line 659 ⟶ 616:
:<code><nowiki>{{#language:nv|en}}</nowiki></code> → {{#language:nv|en}}
parser functions should not appear in the <code>template_list</code> table in the lua logs section of the debug console.
 
==dynamic whitelisting==
 
{| class="wikitable" width="100%"
|+dynamic whitelisting
!template !! rendering
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|Adamson|Mitchell|1911|p=135}}</nowiki></code> || {{Harvard citation no brackets/sandbox|Adamson|Mitchell|1911|p=135}}
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|WhiteJones|BlackBryant|2020|ref=WhiteBlack20201911}}</nowiki></code> || {{Harvard citation no brackets/sandbox|White|BlackJones|2020Bryant|ref=WhiteBlack20201911}}
|-
! colspan="2" | usingsimple {{pipe}}ref=citations
|}-
| <code><nowiki>{{EB1911 |mode=cs2 |last=Adamson |first=Robert |author-link=Robert Adamson (philosopher) |last2=Mitchell |first2=John Malcolm |wstitle=Bacon, Francis |volume=3 |pages=135–152 }}</nowiki></code> || {{EB1911 |mode=cs2 |last=Adamson |first=Robert |author-link=Robert Adamson (philosopher) |last2=Mitchell |first2=John Malcolm |wstitle=Bacon, Francis |volume=3 |pages=135–152 }}
|-
| <code><nowiki>{{cite EB1911 |wstitle=Caesar, Gaius Julius |volume=4 |pages=938–943 |first1=Henry Stuart |last1=Jones |first2=Margaret |last2=Bryant |short=1}}</nowiki></code> || {{cite EB1911 |wstitle=Caesar, Gaius Julius |volume=4 |pages=938–943 |first1=Henry Stuart |last1=Jones |first2=Margaret |last2=Bryant |short=1}}
|-
! colspan="2" | usingcite {{pipe}}ref=catholic encyclopedia anduses {{pipe}}harvidvolume=
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|WhiteFanning|Brown|20201907}}</nowiki></code> || {{Harvard citation no brackets/sandbox|White|BrownFanning|20201907}}
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|WhiteFanning|Red|2020|ref=WhiteRed20201908}}</nowiki></code> || {{Harvard citation no brackets/sandbox|White|Red|2020Fanning|ref=WhiteRed20201908}}
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|Fanning, William Henry Windsor|1913}}</nowiki></code> || {{Harvard citation no brackets/sandbox|Fanning, William Henry Windsor|1913}}
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|Herbermann|1913}}</nowiki></code> || {{Harvard citation no brackets/sandbox|Herbermann|1913}}
|-
! colspan="2" | volume citations
|-
| <code><nowiki>{{Cite CE1913|wstitle =Baptism |first=William Henry Windsor |last=Fanning|volume=2|ref=harv}}</nowiki></code> || {{Cite CE1913|wstitle =Baptism |first=William Henry Windsor |last=Fanning|volume=2|ref=harv}}
|-
| <code><nowiki>{{Catholic|last=Fanning|first=William H. W.|wstitle=Conservator|volume=4|ref=harv}}</nowiki></code> || {{Catholic|last=Fanning|first=William H. W.|wstitle=Conservator|volume=4|ref=harv}}
|-
| <code><nowiki>{{cathEncy|wstitle=Vicar of Christ|author=Fanning, William Henry Windsor}}</nowiki></code> || {{cathEncy|wstitle=Vicar of Christ|author=Fanning, William Henry Windsor}}
|-
| <code><nowiki>{{Cite CE1913 | wstitle = Ecclesiastical Heraldry}}</nowiki></code> || {{Cite CE1913 | wstitle = Ecclesiastical Heraldry}}
|-
! colspan="2" | cite EB9 uses {{pipe}}volume= allows roman numerals
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|WhiteAdamson|Yellow|20201878}}</nowiki></code> || {{Harvard citation no brackets/sandbox|White|YellowAdamson|20201878}}
|-
| <code><nowiki>{{Harvard citation no brackets/sandbox|WhiteBaynes|20201878}}</nowiki></code> || {{Harvard citation no brackets/sandbox|WhiteBaynes|20201878}}
|-
! colspan="2" | volume citations
|-
| <code><nowiki>{{cite EB9 |last=Adamson |first=Robert |authorlink=Robert Adamson (philosopher) |wstitle=Henry St John, Viscount Bolingbroke |volume=4 |pages=4–7}}</nowiki></code> || {{cite EB9 |last=Adamson |first=Robert |authorlink=Robert Adamson (philosopher) |wstitle=Henry St John, Viscount Bolingbroke |volume=4 |pages=4–7}}
|-
| <code><nowiki>{{eb9 |wstitle=Henry St John, Viscount Bolingbroke |volume=IV |pages=4–7}}</nowiki></code> || {{eb9 |wstitle=Henry St John, Viscount Bolingbroke |volume=IV |pages=4–7}}
|}