Template:MIA citation/special: Difference between revisions

From Leftypedia
Jump to navigation Jump to search
(attempt to add switch function that converts arabic numerals to roman in the hyperlink)
mNo edit summary
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
<noinclude>{{lspp}}
<noinclude>{{lspp}}
'''Special case citer.''' Primarily intended for sub-template use by forthcoming MIA cite template, but will definitely come in handy for being called directly, e.g.:
'''Special case citer.''' Primarily intended for sub-template use by MIA cite template, but will definitely come in handy for being called directly, e.g.:


  <nowiki>{{MIA citation/special|capital|3|13}}</nowiki>
  <nowiki>{{MIA citation/special|capital|3|13}}</nowiki>
Line 13: Line 13:
  3 = chapter e.g. 3
  3 = chapter e.g. 3
  4 = link e.g. https:// etc. etc.
  4 = link e.g. https:// etc. etc.
==Covered works==
* [[Capital (book)|Capital]]
* [[WITBD]]
[[category:MIA citation template]]
[[category:MIA citation template]]
</noinclude>{{#switch:{{{work|{{{1|capital}}}}}}<!--
</noinclude>{{#switch:{{{work|{{{1|capital}}}}}}<!--
Line 45: Line 50:
     | fail
     | fail
     }} <!--
     }} <!--
https://www.marxists.org/archive/lenin/works/1901/witbd/i.htm
 
2.?: Hyperlink. Essentially builds a hyperlink if none is found. Converts Arabic numerals into roman numerals etc. to make it fit the hyperlink format.
2.?: Hyperlink. Essentially builds a hyperlink if none is found. Converts Arabic numerals into roman numerals etc. to make it fit the hyperlink format.
-->[{{if then show|{{{link|{{{4|}}}}}}|https://www.marxists.org/archive/lenin/works/witbd/{{#switch: {{{chapter|{{{3|}}}}}} | 1 = i | 2 = ii | 3 = iii | 4 = iv | 5 = v | conclusion = concl | correction = correctn | {{{chapter|{{{3|}}}}}}}}.htm}} Available online]<!--
-->[{{if then show|{{{link|{{{4|}}}}}}|https://www.marxists.org/archive/lenin/works/1901/witbd/{{#switch: {{{chapter|{{{3|}}}}}} | 1 = i | 2 = ii | 3 = iii | 4 = iv | 5 = v | conclusion = concl | correction = correctn | {{if empty|{{{chapter|{{{3|index}}}}}}}}|index}}.htm}} Available online]<!--


Other works:
Other works:
-->|
-->|
  }}
  }}

Latest revision as of 00:23, 14 June 2024

In this templatespace:

Template talk:

Special case citer. Primarily intended for sub-template use by MIA cite template, but will definitely come in handy for being called directly, e.g.:

{{MIA citation/special|capital|3|13}}

Producing:

In this way, one can cite a given MIA text without having to grab the link, providing an option that some may find to be a time-saver. However, i have no idea whether creating several sub-templates is a resource issue versus putting them under the regular MIA citation template as "special cases"; as such, i will leave SUS and Manifesto there for now even though they would be immensely handy, and editing them like this - without having to deal with endless sub-curly-brackets and functions and whatnot - would be probably easier. -Harry 6/6/24

1 = work e.g. capital
2 = volume e.g. 1
3 = chapter e.g. 3
4 = link e.g. https:// etc. etc.

Covered works

Marx, Karl & Engels, Friedrich (1867). Capital, Volume I. Chapter : [[Das Kapital, Volume I, Chapter Lua error in Module:ConvertNumeric at line 576: Invalid decimal numeral.: |"."]] Expression error: Unexpected > operator..htm Available online