Template:Infobox chemical/sandbox

From blackwiki
Jump to navigation Jump to search
Template documentation[view] [edit] [history] [purge]

Template:Parameter names example

Template {{Infobox chemical}} is an infobox for chemicals. It has a large number of options to add relevant data and images. The infobox is organized in sections like "identifiers" and "hazards".

Usage

The Infobox has a modular design. After the general information like the chemical name and images, it can be built from multiple sections, each covering a group of information (like "pharmacology"). Depending on the compound, sections can be added or left out, and within a section parameters can be added or omitted (left blank).

The sections and their parameters are listed below.

Within the general template (with its own parameters like |ImageFile= and |IUPACName=), each section is added with this pattern (as the value of a parameter |Sectionx=.

{{Infobox chemical
| ImageFile = 
| IUPACName = 
<!-- more general Infobox chemical parameters here -->
| Section1 = {{Infobox chemical/identifiers
| CASNo = 
| PubChem = 
<!-- more Identifier parameters here -->
  }}
}}

In this format, spaces and new lines have no meaning and can be used freely to separate sections (though within a data value, a space has a meaning, except generally leading and trailing spaces). Each section has its own number in |Section#=. Then a section is defined with "|Section# = {{Infobox chemical/" and ends with "}}". Sections cannot 'nest': one must close one section with }} before adding another |Section#= {{Infobox chemical/ ....

Keep in mind the advice in the main Infobox documentation to use the {{Unbulleted list}} template to present multiple values for a parameter so as to ensure that the values are each started on a new line and tagged appropriately in the underlying markup. This is particularly important with parameters like |OtherNames=, since many names use commas within them, and using commas as separators leads to ambiguity. For example:

| OtherNames = {{Unbulleted list
  | 2,4,6(1''H'',3''H'',5''H'')-pyrimidinetrione
  | 2,4,6-trioxohexahydropyrimidine
  | pyrimidinetriol
  | malonylurea
  | 6-hydroxyuracil
  | ''N'',''N''-(1,3-dioxo-1,3-propanediyl)urea
  }}
| (next parameter) = <!-- etc. -->


Small, simple form

To use, simply copy and paste the left column into the document, filling in whatever you can, and save:

Template:Pre2 Template:Pre2

Medium form

To use, simply copy and paste the left column into the document, filling in whatever you can:

Template:Pre2 Template:Pre2

Full form

To use, simply copy and paste the left column into the document, and press save to get an empty infobox:

Long parameter list for {{Infobox chemical}}
Template:Pre2 Template:Pre2

Indexed parameters

| CASNo = 
| CASNo1 = 
| CASNo2 = 
| CASNo3 = 
| CASNo4 = 
| CASNo5 = 
| CASNoOther = 
Indexed parameters

Overview
(index numbers 2-3-4 omitted):

| CASNo =
| CASNo1 =
| CASNo5 =
| CASNoOther =
| ChEBI =
| ChEBI1 =
| ChEBI5 =
| ChEBIOther =
| ChEMBL =
| ChEMBL1 =
| ChEMBL5 =
| ChEMBLOther =
| ChemSpiderID =
| ChemSpiderID1 =
| ChemSpiderID5 =
| ChemSpiderIDOther =
| DrugBank =
| DrugBank1 =
| DrugBank5 =
| DrugBankOther =
| InChI =
| InChI1 =
| InChI5 =
| InChIOther =
| KEGG =
| KEGG1 =
| KEGG5 =
| KEGGOther =
| PubChem =
| PubChem1 =
| PubChem5 =
| PubChemOther =
| SMILES =
| SMILES1 =
| SMILES5 =
| SMILESOther =
| UNII =
| UNII1 =
| UNII5 =
| UNIIOther =

Indexed parameters take indexes 'blank', 1–5 (six options together). They should have straight input, such as a correct CAS Registry Number.

  • Eight base parameters are indexed this way, all identifiers:
CASNo, ChEBI, ChEMBL, ChemSpiderID, DrugBank, InChI, KEGG, PubChem, SMILES, UNII
  • Then |_Other= (like |CASNoOther=) is available for free text input.
same substance, same index

When the infobox has multiple substances, you can use the index. Make sure that |CASNo3= and |SMILES3= are about the same substance, and |CASNo3= and |SMILES2= are not. Treat index "0" the same way:

|CASNo= is |InChI= is |SMILES=
|CASNo1= is |InChI1= is |SMILES1=
|CASNo= is not |InChI1= is not |SMILES4=
Labeling the substances

By using a parameter like |index2_label=, you can prefix every #2-input with that same prefix.

{{Infobox chemical
 | Name=[[Linalool]]
 | Section1={{Infobox chemical/identifiers
 | index_label    = 
 | index1_label   = (''R'')
 | index2_label   = (''S'')
 | index_comment  = (+/-)-linalool 
 | index1_comment = (-)-linalool
 | index2_comment = (+)-linalool
 | CASNo          = 78-70-6
 | CASNo1         = 126-91-0
 | CASNo2         = 126-90-9
 | PubChem        = 6549
 | PubChem1       = 443158
 | PubChem2       = 67179
 }}
}}






Linalool
Identifiers
  • Compounds
  • (+/-)-linalool
  • (R): (-)-linalool
  • (S): (+)-linalool
ECHA InfoCardScript error: No such module "Wikidata". Script error: No such module "Wikidata".
E numberScript error: No such module "Wikidata".
Except where otherwise noted, data are given for materials in their standard state (at 25 °C [77 °F], 100 kPa).
Infobox references
| CASNo_Comment =
| CASNo1_Comment =
| CASNo5_Comment =
  • For specific additions, each parameter has a |_Comment= option.

Section subtemplates

The following section subtemplates are available:

And the automated section, that is visible when 'pagename (data page)' exists:

See these subsections for their parameter options.

The order of these sections in the infobox is set by the section number (|Section#=) only. Not by the typed sequence. This documentation keeps this arbitrary order:

| Section1 = {{Infobox chemical/identifiers}}
| Section2 = {{Infobox chemical/properties}}
| Section3 = {{Infobox chemical/structure}}
| Section4 = {{Infobox chemical/thermochemistry}}
| Section5 = {{Infobox chemical/explosive}}
| Section6 = {{Infobox chemical/pharmacology}}
| Section7 = {{Infobox chemical/hazards}}
| Section9 = {{Infobox chemical/related}}

Sections that are not used can be safely removed, renumbering is not necessary.

Empty Syntax

{{Infobox chemical
| Name             = 
| Reference        = 
| Chembox_ref      = 
| ImageFile        = 
| ImageSize        = 
| ImageName        = 
| ImageAlt         = 
| ImageCaption     = 
| ImageFile_Ref    = 
| ImageFile1       = 
| ImageSize1       = 
| ImageName1       = 
| ImageAlt1        = 
| ImageCaption1    = 
| ImageFile1_Ref   = 
| ImageFileL1      = 
| ImageFileR1      = 
| ImageSizeL1      = 
| ImageNameL1      = 
| ImageAltL1       = 
| ImageCaptionL1   = 
| ImageFileL1_Ref  = 
| ImageSizeR1      = 
| ImageNameR1      = 
| ImageAltR1       = 
| ImageCaptionR1   = 
| ImageFileR1_Ref  = 
| ImageCaptionLR1  = 
| ImageFile2       = 
| ImageSize2       = 
| ImageName2       = 
| ImageAlt2        = 
| ImageCaption2    = 
| ImageFile2_Ref   = 
| ImageFileL2      = 
| ImageFileR2      = 
| ImageSizeL2      = 
| ImageNameL2      = 
| ImageAltL2       = 
| ImageCaptionL2   = 
| ImageFileL2_Ref  = 
| ImageSizeR2      = 
| ImageNameR2      = 
| ImageAltR2       = 
| ImageCaptionR2   = 
| ImageFileR2_Ref  = 
| ImageCaptionLR2  = 
| ImageFile3       = 
| ImageSize3       = 
| ImageName3       = 
| ImageAlt3        = 
| ImageCaption3    = 
| ImageFile3_Ref   = 
| ImageFileL3      = 
| ImageFileR3      = 
| ImageSizeL3      = 
| ImageNameL3      = 
| ImageAltL3       = 
| ImageCaptionL3   = 
| ImageFileL3_Ref  = 
| ImageSizeR3      = 
| ImageNameR3      = 
| ImageAltR3       = 
| ImageCaptionR3   = 
| ImageFileR3_Ref  = 
| ImageCaptionLR3  = 
| ImageCaptionAll  = 
| OtherNames       = 
| IUPACName        = 
| IUPACNames       = 
| PIN              = 
| SystematicName   = 
| pronounce        = 
| Names_ref        = 
| Section1         = 
| Section2         = 
| Section3         = 
| Section4         = 
| Section5         = 
| Section6         = 
| Section7         = 
| Section8         = 
| show_footer      = 
| show_ss_note     = 
| general_note     = 
| Verifiedfields   = 
| verifiedrevid    = 
| show_infobox_ref = 
}}

See also

Old {{chembox}} version {{Infobox chemical}} equivalent Testcases
{{Chembox Identifiers}} {{Infobox chemical/identifiers}} testcases
{{Chembox Properties}} {{Infobox chemical/properties}} testcases
{{Chembox Structure}} {{Infobox chemical/structure}} testcases
{{Chembox Thermochemistry}} {{Infobox chemical/thermochemistry}} testcases
{{Chembox Explosive}} {{Infobox chemical/explosive}} testcases
{{Chembox Pharmacology}} {{Infobox chemical/pharmacology}} testcases
{{Chembox Hazards}} {{Infobox chemical/hazards}} testcases
{{Chembox Related}} {{Infobox chemical/related}} testcases
{{Chembox Supplement}} {{Infobox chemical/supplement}} testcases
Additional templates
{{Infobox chemical/image row}}
{{Infobox chemical/labelstyle}}
{{Infobox chemical/datastyle}}
{{Infobox chemical/calc temps}}

Template Data

TemplateData documentation used by VisualEditor and other tools
See the monthly parameter usage report for this template.

TemplateData for Infobox chemical

No description.

Template parameters

ParameterDescriptionTypeStatus
NameName

Name of the Chemical

Default
{{PAGENAME}}
Example
Sulfuric Acid
Stringoptional
ReferenceReference Chembox_ref

Reference, use <ref>...</ref> and add <references /> to the page

Unknownoptional
Image file nameImageFile

Name of the file

Example
Placeholder.png
Fileoptional
Image sizeImageSize

The size of the image

Unknownoptional
Image titleImageName

Title for the image

Example
Amino Acid Bottle
Unknownoptional
Image altImageAlt

Image alt

Example
A picture of the chemical bottle
Stringoptional
Image captionImageCaption

Caption for the image

Example
A picture of the chemical
Stringoptional
Image ReferenceImageFile_Ref

Reference that goes after the caption

Example
<ref>{{cite web|...}}</ref>
Stringoptional
Image file name 1ImageFile1

Name of the file for image 1

Example
Placeholder.png
Fileoptional
Image size 1ImageSize1

The size of image 1

Unknownoptional
ImageName1ImageName1

no description

Unknownoptional
ImageAlt1ImageAlt1

no description

Unknownoptional
ImageCaption1ImageCaption1

no description

Unknownoptional
ImageFile1_RefImageFile1_Ref

no description

Unknownoptional
Image file name 2ImageFile2

Name of the file for image 2

Example
Placeholder.png
Fileoptional
Image size 2ImageSize2

The size of image 2

Unknownoptional
ImageName2ImageName2

no description

Unknownoptional
ImageCaption2ImageCaption2

no description

Unknownoptional
ImageAlt2ImageAlt2

no description

Unknownoptional
ImageFile2_RefImageFile2_Ref

no description

Unknownoptional
Image file name 3ImageFile3

Name of the file for image 3

Fileoptional
Image size 3ImageSize3

The size of image 3

Unknownoptional
ImageName3ImageName3

no description

Unknownoptional
ImageCaption3ImageCaption3

no description

Unknownoptional
ImageAlt3ImageAlt3

no description

Unknownoptional
ImageFile3_RefImageFile3_Ref

no description

Unknownoptional
Image file name L1ImageFileL1

Name of the file for image L1

Example
Placeholder.png
Fileoptional
Image size L1ImageSizeL1

The size of image L1

Unknownoptional
ImageNameL1ImageNameL1

no description

Unknownoptional
ImageAltL1ImageAltL1

no description

Unknownoptional
ImageCaptionL1ImageCaptionL1

no description

Unknownoptional
ImageFileL1_RefImageFileL1_Ref

no description

Unknownoptional
Image file name R1ImageFileR1

Name of the file for image R1

Example
Placeholder.png
Fileoptional
Image size R1ImageSizeR1

The size of image R1

Unknownoptional
ImageNameR1ImageNameR1

no description

Unknownoptional
ImageAltR1ImageAltR1

no description

Unknownoptional
ImageCaptionR1ImageCaptionR1

no description

Unknownoptional
ImageFileR1_RefImageFileR1_Ref

no description

Unknownoptional
Image caption L1+R1ImageCaptionLR1

Caption for both L1 and R1

Unknownoptional
Image file name L2ImageFileL2

Name of the file for image L2

Example
Placeholder.png
Fileoptional
Image size L2ImageSizeL2

The size of image L2

Unknownoptional
ImageNameL2ImageNameL2

no description

Unknownoptional
ImageAltL2ImageAltL2

no description

Unknownoptional
ImageCaptionL2ImageCaptionL2

no description

Unknownoptional
ImageFileL2_RefImageFileL2_Ref

no description

Unknownoptional
Image file name R2ImageFileR2

Name of the file for image R2

Example
Placeholder.png
Fileoptional
Image size R2ImageSizeR2

The size of image E2

Unknownoptional
ImageNameR2ImageNameR2

no description

Unknownoptional
ImageAltR2ImageAltR2

no description

Unknownoptional
ImageCaptionR2ImageCaptionR2

no description

Unknownoptional
ImageFileR2_RefImageFileR2_Ref

no description

Unknownoptional
Image caption L2+R2ImageCaptionLR2

Caption for both L2 and R2

Unknownoptional
Image file name L3ImageFileL3

Name of the file for image L3

Example
Placeholder.png
Fileoptional
Image size L3ImageSizeL3

The size of image L3

Unknownoptional
ImageNameL3ImageNameL3

no description

Unknownoptional
ImageAltL3ImageAltL3

no description

Unknownoptional
ImageCaptionL3ImageCaptionL3

no description

Unknownoptional
ImageFileL3_RefImageFileL3_Ref

no description

Unknownoptional
Image file name R3ImageFileR3

Name of the file for image R3

Example
Placeholder.png
Fileoptional
Image size L3ImageSizeR3

no description

Unknownoptional
ImageNameR3ImageNameR3

no description

Unknownoptional
ImageAltR3ImageAltR3

no description

Unknownoptional
ImageCaptionR3ImageCaptionR3

no description

Unknownoptional
ImageFileR3_RefImageFileR3_Ref

no description

Unknownoptional
Image caption L3+R3ImageCaptionLR3

Caption for both L3 and R3

Unknownoptional
ImageCaptionAllImageCaptionAll

Caption for ball images

Unknownoptional
OtherNamesOtherNames

no description

Unknownoptional
IUPACNameIUPACName

IUPAC name

Unknownoptional
IUPACNamesIUPACNames

no description

Unknownoptional
PINPIN

The prefered name

Unknownoptional
SystematicNameSystematicName

The systematic name(s)

Unknownoptional
Pronouncepronounce

The pronunciation of the name

Unknownoptional
Names_refNames_ref

Reference for the name, use <ref>...</ref> and add <references /> to the page

Unknownoptional
Section 1Section1

Section 1 (generally {{Infobox chemical/identifiers}})

Templateoptional
Section 2Section2

Section 2 (generally {{Infobox chemical/properties}})

Templateoptional
Section 3Section3

Section 3 (generally {{Infobox chemical/structure}})

Templateoptional
Section 4Section4

Section 4 (generally {{Infobox chemical/thermochemistry}})

Templateoptional
Section 5Section5

Section 5 (generally {{Infobox chemical/pharmacology}})

Templateoptional
Section 6Section6

Section 6 {{Infobox chemical/pharmacology}}

Templateoptional
Section 7Section7

Section 7 (generally {{Infobox chemical/hazards}})

Templateoptional
Section 8Section8

Section 8

Templateoptional
Section 9Section9

Section 9 (generally {{Infobox chemical/related}})

Templateoptional
Data page pagenamedata page pagename

A non-default data page name

Default
[[{{FULLPAGENAME}}(data page)]]
Example
[[Ammonia (data page)]]
Pageoptional
Show_footershow_footer

no description

Unknownoptional
Show_ss_noteshow_ss_note

no description

Unknownoptional
General_notegeneral_note

no description

Unknownoptional
VerifiedfieldsVerifiedfields

no description

Unknownoptional
Verifiedrevidverifiedrevid

no description

Unknownoptional
Show_infobox_refshow_infobox_ref

no description

Unknownoptional

Tracking categories

Categories

/Hazards
/Pharmacology
/Supplement
Tracking