Difference between revisions of "Template:Bibcode/doc"
Jump to navigation
Jump to search
imported>Funandtrvl m (cat refine) |
imported>Vanisaac m (→See also: clean up per WP:CAT#T and WP:AWBREQ add template:Sandbox other) |
||
| (11 intermediate revisions by 10 users not shown) | |||
| Line 1: | Line 1: | ||
{{Documentation subpage}} | {{Documentation subpage}} | ||
| + | {{lua|Module:check bibcode}} | ||
| + | This template is intended to allow simple standardized links to [[bibcode]]s. For example, <nowiki>{{bibcode|1998ApJ...508L..81K}}</nowiki> will produce {{bibcode|1998ApJ...508L..81K}} external link. | ||
| − | + | ==Syntax== | |
| + | {{tlx|bibcode|place_bibcode_id_number_here}} | ||
| + | |||
| + | ==Example== | ||
| + | {{tlx|bibcode|1998ApJ...508L..81K}} | ||
| + | |||
| + | {{bibcode|1998ApJ...508L..81K}} | ||
| + | |||
| + | ==Error messages== | ||
| + | The Bibcode template checks the bibcode value to see if it has the proper format.<ref>{{cite web |url=http://adsabs.harvard.edu/abs_doc/help_pages/data.html#bibcodes |title=1.2.3 - Bibliographic Identifiers |website=The SAO/NASA Astrophysics Data System}}</ref> When the assigned value does not have the proper format, the template returns an error message along with the type of error that is encountered: | ||
| + | :<span class="error" style="font-size:100%">Check bibcode: <type></span> | ||
| + | Bibcode template values are expected to match these requirements: | ||
| + | :length must be 19 characters (<type> = '<span class="error" style="font-size:100%">length</span>') | ||
| + | :characters in position(s): (except as specified otherwise, violations produce '<span class="error" style="font-size:100%">value</span>' in the <type> portion of the error message): | ||
| + | ::1–4 must be digits and must represent a year in the range of 1000 – next year (<type> = '<span class="error" style="font-size:100%">year</span>') | ||
| + | ::5 must be a letter | ||
| + | ::6–8 must be letter, ampersand, or dot (ampersand cannot directly precede a dot; &. (<type> = '<span class="error" style="font-size:100%">journal</span>')) | ||
| + | ::9 must be letter or dot | ||
| + | ::10–18 must be letter, digit, or dot | ||
| + | ::19 must be a letter or dot | ||
| + | To resolve this error, ensure that the assigned bibcode value is correct. | ||
==See also== | ==See also== | ||
| Line 11: | Line 33: | ||
* [[Template:doi-inline]] | * [[Template:doi-inline]] | ||
| − | <includeonly> | + | <includeonly>{{Sandbox other|| |
| + | [[Category:Catalog lookup templates]] | ||
[[Category:Astronomy external link templates|{{PAGENAME}}]] | [[Category:Astronomy external link templates|{{PAGENAME}}]] | ||
| Line 17: | Line 40: | ||
[[id:Templat:Bibcode]] | [[id:Templat:Bibcode]] | ||
[[ja:Template:Bibcode]] | [[ja:Template:Bibcode]] | ||
| − | </includeonly> | + | [[sl:Predloga:Bibcode]] |
| + | }}</includeonly> | ||
Latest revision as of 23:53, 23 April 2020
| This is a documentation subpage for Template:Bibcode. It contains usage information, categories and other content that is not part of the original template page. |
| This template uses Lua: |
This template is intended to allow simple standardized links to bibcodes. For example, {{bibcode|1998ApJ...508L..81K}} will produce Bibcode:1998ApJ...508L..81KTemplate:Only in print external link.
Contents
Syntax
{{bibcode|place_bibcode_id_number_here}}
Example
{{bibcode|1998ApJ...508L..81K}}
Bibcode:1998ApJ...508L..81KTemplate:Only in print
Error messages
The Bibcode template checks the bibcode value to see if it has the proper format.[1] When the assigned value does not have the proper format, the template returns an error message along with the type of error that is encountered:
- Check bibcode: <type>
Bibcode template values are expected to match these requirements:
- length must be 19 characters (<type> = 'length')
- characters in position(s): (except as specified otherwise, violations produce 'value' in the <type> portion of the error message):
- 1–4 must be digits and must represent a year in the range of 1000 – next year (<type> = 'year')
- 5 must be a letter
- 6–8 must be letter, ampersand, or dot (ampersand cannot directly precede a dot; &. (<type> = 'journal'))
- 9 must be letter or dot
- 10–18 must be letter, digit, or dot
- 19 must be a letter or dot
To resolve this error, ensure that the assigned bibcode value is correct.
See also
- ↑ "1.2.3 - Bibliographic Identifiers". The SAO/NASA Astrophysics Data System.