defzone.net@gmail.comLiên hệ
DZ
DefZone.Net

Kien thuc cong nghe & giai tri

Bai vietDia diemAlbum anhGameCua hang
  1. Home
  2. Wiki
Template documentation[view] [edit] [history] [purge]
CSSThis template uses TemplateStyles:
  • Template:Chart/styles.css
ChartThis template uses the Chart extension with sources from Wikimedia Commons.

Copy templates

[edit]

Standard

{{Chart|chart=.chart}}

Full

{{Chart
| chart      = 
| data       = 
| thumb      =
| align      = 
| width      = 
| border     = 
| style      = 
| caption    =
| source     = 
}}

or

{{Chart|thumb|align|width|caption|chart=.chart|data=.tab|border=|style=|source=.tab}}

Examples

[edit]

full width

[edit]
{{Chart
| chart = Autobahn network length.Line.chart
}}
Length in kilometresYear03K6K9K12K15K1932195019851999200620132020ReichsautobahnBundesautobahn (West Germany)Bundesautobahn (Germany)Development of the length of the Reichsautob...
View chart definition.

other data source and border

[edit]
{{Chart
| chart      = Monthly stream discharges.chart
| data       = GRDC-1530100 monthly discharge.tab
| border     = 1
}}
Discharge in m³/sMonth0100200300400500JanMarMayJulSepNovMinMeanMaxHydrograph: Monthly discharge
View source data.

thumbnail, caption, and source

[edit]
{{Chart
| thumb
| caption = Autobahn network length.
| source  = Autobahn network length.tab
| chart   = Autobahn network length.Line.chart
}}
Length in kilometresYear03K6K9K12K15K1932195019851999200620132020ReichsautobahnBundesautobahn (West Germany)Bundesautobahn (Germany)Development of the length of the Reichsautob...
Autobahn network length. View source data.

aligned and fixed width

[edit]
{{Chart
| chart      = Autobahn network length.Line.chart
| align      = right
| width      = 400px
}}
Length in kilometresYear03K6K9K12K15K1932195019851999200620132020ReichsautobahnBundesautobahn (West Germany)Bundesautobahn (Germany)Development of the length of the Reichsautob...
View chart definition.

aligned and fixed width thumbnail

[edit]
{{Chart
| thumb
| chart      = Autobahn network length.Line.chart
| align      = left
| width      = 400px
}}
Length in kilometresYear03K6K9K12K15K1932195019851999200620132020ReichsautobahnBundesautobahn (West Germany)Bundesautobahn (Germany)Development of the length of the Reichsautob...
View chart definition.

centered, fixed width, border, caption and source

[edit]
{{Chart
| chart      = Autobahn network length.Line.chart
| align      = center
| width      = 400px
| caption    = Autobahn network length.
| source     = Autobahn network length.tab
}}
Length in kilometresYear03K6K9K12K15K1932195019851999200620132020ReichsautobahnBundesautobahn (West Germany)Bundesautobahn (Germany)Development of the length of the Reichsautob...
Autobahn network length. View source data.

TemplateData

[edit]
This is the TemplateData for this template used by TemplateWizard, VisualEditor and other tools. See a monthly parameter usage report for Template:Chart in articles based on its TemplateData.

TemplateData for Chart

Includes a chart ([[Help:Charts]]) with source attribution and allows adjusting alignment, width, and border.

Template parameters[Edit template data]

ParameterDescriptionTypeStatus
Display as thumbnailthumb 1

Set to any value to display in a gray box like an image thumbnail

Suggested values
thumb
Example
thumb
Lineoptional
Alignmentalign 2

Chart alignment, either "left", "right", or "center"

Suggested values
left right center
Lineoptional
Widthwidth 3

Width in pixels or percent

Suggested values
400px 600px 50% 100%
Lineoptional
Captioncaption 4

Caption to display before the source information. Make sure to use ending punctuation.

Example
This is a chart caption.
Stringoptional
Chart definitionchart definition

Chart on Wikimedia Commons, without the "Data:" prefix

Example
Example.chart
Linerequired
Chart datadata

.tab on Wikimedia Commons, without the "Data:" prefix (overrides the specification in the chart definition)

Example
Example.tab
Linesuggested
Source attributionsource

Source .tab file to be linked at the bottom, without the "Data:" prefix. If not specified, it will fallback to displaying the value of "data" or "chart".

Example
Example.tab
Linesuggested
Borderborder

Set to "1" to enable a border

Suggested values
1
Example
1
Booleanoptional
CSS stylesstyle

Additional CSS styles (beyond width and border)

Example
border-width:5px;
Lineoptional
Hide sourcehideSource

Set to any value to disable linking to the source

Suggested values
1
Example
1
Booleanoptional

See also

[edit]
  • Wikipedia:Graphs and charts
  • {{Image frame}}
The above documentation is transcluded from Template:Chart/doc. (edit | history)
Editors can experiment in this template's sandbox (edit | diff) and testcases (edit) pages.
Add categories to the /doc subpage. Subpages of this template.
DZ
DefZone.Net

Noi chia se kien thuc, huong dan va kham pha cong nghe.

Lien ket nhanh

Trang chủBài viếtWikiCửa hàngLiên hệ

Liên hệ

Email: defzone.net@gmail.com
Điện thoại: +84 762 559 696
Địa chỉ: Thiên Hương, Thủy Nguyên, Hải Phòng

Đăng ký nhận tin

Nhận bài viết và cập nhật mới nhất qua email.

© 2025 DefZone.Net. All rights reserved.
PrivacyTermsSitemap