Difference between revisions of "Template:LCCN/doc"

From blackwiki
Jump to navigation Jump to search
imported>He7d3r
m (→‎See also: *bugzilla:8160: ParserFunction for Library of Congress Control Numbers (LCCN))
imported>Smith609
(Simplify)
Line 3: Line 3:
  
 
===Usage===
 
===Usage===
This template is used for referring to books by their [[Library of Congress Control Number]]s. Split the number into 3 parameters:
+
This template is used for referring to books by their [[Library of Congress Control Number]]s. Enter the LCCN without any dashes.
#the numbers before the dash
 
#if the number after the dash is not 6 digits long, enough zeroes to make it so
 
#the numbers after the dash
 
  
 
E.g.: to link 89-456 it'll be
 
E.g.: to link 89-456 it'll be
#89
+
<nowiki>{{LCCN|89456}}</nowiki> gives
#000
+
{{LCCN|89456}}
#456
 
  
<nowiki>{{LCCN|89|000|456}}</nowiki> gives
 
{{LCCN|89|000|456}}
 
 
To link a number that already has 6 digits after the dash, leave the 2nd parameter empty. E.g.: for 71-143545
 
#71
 
#&nbsp;
 
#143545
 
 
<nowiki>{{LCCN|71||143545}}</nowiki> gives
 
{{LCCN|71||143545}}
 
 
If the LCCN has 8 digits and no dash, treat it as if there is a dash after the second number.  E.g. for 71143545
 
#71
 
#&nbsp;
 
#143545
 
 
<nowiki>{{LCCN|71||143545}}</nowiki> gives
 
{{LCCN|71||143545}}
 
 
If the LCCN has 10 digits and no dash, put the first four numbers (the year it was assigned) in the first parameter, leave the second parameter blank, and put the last six numbers in the third parameter. E.g.: for 2001022631
 
#2001
 
#&nbsp;
 
#022631
 
 
<nowiki>{{LCCN|2001||022631}}</nowiki> gives
 
{{LCCN|2001||022631}}
 
 
If the LCCN contains two letters, add them before the normal 1st parameter:
 
 
<nowiki>{{LCCN|sa65|00|3567}}</nowiki> gives
 
<nowiki>{{LCCN|sa65|00|3567}}</nowiki> gives
 
{{LCCN|sa65|00|3567}}
 
{{LCCN|sa65|00|3567}}

Revision as of 04:24, 19 March 2011

Usage

This template is used for referring to books by their Library of Congress Control Numbers. Enter the LCCN without any dashes.

E.g.: to link 89-456 it'll be {{LCCN|89456}} gives LCCN Expression error: Unrecognized punctuation character "[". 89-Expression error: Unrecognized punctuation character "[".Template:Only in print

{{LCCN|sa65|00|3567}} gives LCCN Expression error: Unrecognized punctuation character "[". sa65-Expression error: Unrecognized punctuation character "[". – 00Template:Only in print

See also