模板:Div col end

維基文庫,自由的圖書館
跳到导航 跳到搜索
模板文档


This template is a shortcut for producing columns using CSS (more info). It generates the CSS for various browsers. Supported browsers are the current versions of Firefox, Safari and Chrome.

Usage[编辑]

This template is used to make a list into columns, with the option of specifying a smaller font. It is used when the point at which the columns are broken does not need to be set exactly, since it will be chosen automatically by the browser.

If you need to set to column break exactly, use {{multicol}}.

Parameters[编辑]

  • {{{1}}}, {{{cols}}}: Specifies the number of columns. Defaults to 2.
  • {{{small}}}: Specifies small font size (80%). Defaults to "no".

Examples[编辑]

Lists[编辑]

{{Div col}}
* a
* b
* c
* d
{{Div col end}}
  • a
  • b
  • c
  • d

Prose[编辑]

{{Div col|cols=6}}{{lorem ispsum}}
{{Div col end}}
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo.

Small[编辑]

{{Div col|small=yes}}{{lorem ispsum}}
{{Div col end}}
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo.

See also[编辑]

Help:Templates