[wordpress插件] Columns for Bootstrap引导程序列

wordpress 插件 文章 2020-03-28 00:40 433 0 全屏看文

AI助手支持GPT4.0

评分
0
描述

Code is adapted from the plugin ‘Columns’ by Konstantin Kovshenin.

代码改编自Konstantin Kovshenin的“专栏”插件。

Bootstrap is an HTML, CSS, and JS framework that is used to develop responsive, mobile websites.

Bootstrap是一个HTML,CSS和JS框架,用于开发响应式移动网站。

It employs a grid system that divides the viewport into twelve distinct columns.

它采用了将视口分为十二个不同列的网格系统。

On desktops, the columns scale proportionally to the width of the viewing area while on mobile devices and tablets the columns stack on top of one another.

在台式机上,这些列与查看区域的宽度成比例地缩放,而在移动设备和平板电脑上,这些列彼此堆叠。

This plugin takes advantage of that grid system to allow for WordPress content to be split up equally between the twelve columns.

该插件利用该网格系统的优势,可以将WordPress内容在十二列之间平均分配。

To create a group of columns, use the [column-group] shortcode.

要创建一组列,请使用 [column-group] 短代码。

To add columns to a group, use the [column] shortcode.

要将列添加到组,请使用 [column] 短代码。

For example:

例如:

[column-group]        

  [column-group]        

[column]This is the first column[/column]        

[column]这是第一列[/ column]        

[column]This is the second column[/column]

[专栏]这是第二栏[/专栏]

[/column-group]

[/ column-group]

The first column will occupy the first six columns of the Bootstrap grid while the second column will fill the remaining six.

第一列将占据Bootstrap网格的前六列,第二列将填充其余六列。

Spanning Columns

跨栏

The plugin’s columns can also be manually spanned across the Bootstrap grid.

也可以在Bootstrap网格中手动扩展插件的列。

By adding the span attribute to the starting column shortcode, the number of Bootstrap columns that the WordPress columns take up can be assigned.

通过将 span 属性添加到起始列短代码中,可以分配WordPress列占用的Bootstrap列数。

For example:

例如:

[column-group]        

  [column-group]        

[column span=“4”]This is the first column.[/column]        

[column span =“ 4”]这是第一列。[/ column]        

[column span=“6”]This is the second column.[/column]        

[column span =“ 6”]这是第二列。[/ column]        

[column span=“2”]This is the third column.[/column]

[column span =“ 2”]这是第三列。[/ column]

[/column-group]

[/ column-group]

The columns will take up four, six, and two of the Bootstrap columns respectively.

这些列将分别占用Bootstrap列的四个,六个和两个。

Note: The span value is actually a ratio so if the total value of the spans in a column group does not equal twelve, then the plugin will assign the column sizes by means of percentage.

注意:跨度值实际上是一个比率,因此,如果列组中跨度的总值不等于十二,则插件将通过百分比分配列大小。

安装步骤

    1. Make sure that the current WordPress theme is built with Bootstrap.
    2. 确保当前的WordPress主题是使用Bootstrap构建的。

    3. Download archive and unzip in wp-content/plugins or install via Plugins – Add New.
    4. 下载存档并解压缩到wp-content / plugins或通过Plugins – Add New安装。

    5. Activate the Columns for Bootstrap plugin.
    6. 激活 Bootstrap列插件。

    7. Check the top of the Plugins page for any warnings.
    8. 检查“插件”页面顶部是否有任何警告。

    9. Begin using the [column-group] and [column] shortcodes.
    10. 开始使用 [column-group] [column] 短代码。

下载地址
https://downloads.wordpress.org/plugin/columns-for-bootstrap.zip
-EOF-

AI助手支持GPT4.0