[wordpress插件] Advanced Custom Fields: Price Field高级自定义字段:价格字段

wordpress 插件 文章 2020-01-27 05:00 503 0 全屏看文

AI助手支持GPT4.0

评分

100

100

描述

How it works

工作原理

    • Plugin will store your “price” as float so any time you will change desire number format there will be no reformatting problems.
    • 插件将您的“价格”存储为浮点数,因此任何时候您更改需求数字格式都不会出现重新格式化的问题。

    • Best column type in database for “price” related fields is decimal.

    • 数据库中与“价格”相关的字段的最佳列类型为十进制。

      As WordPress keep meta as type “text” I can only cast it to float.

      由于WordPress将meta保留为“文本”类型,因此我只能将其强制转换为浮动。

      Keep it in mind.

    • 请记住。

    • Field validation is “live” thanks to https://github.com/teamdf/jquery-number.
    • 由于https://github.com/teamdf/jquery-number,字段验证是“实时的”。

    • When you use get_field function you will get preformatted number based on your settings.
    • 使用 get_field 函数时,您将根据设置获得预格式化的号码。

    Options

    选项

    format

     格式

    Available formats:

    可用格式:

    * 1 337.55

    * 1 337.55

    * 1 337,55

    * 133755

    * 1,337.55

    * 1,337.55

    * 1.337,55

    * 1.337,55

    * 1337

    * 1337

    * 1 337

    * 1 337

    Default parameters result

    默认参数结果

    1 337.00

      1 337.00

    Compatibility

    兼容性

    This ACF field type is compatible with:

    此ACF字段类型兼容:

    * ACF 5

    * ACF 5

    * ACF 4

    * ACF 4

安装步骤

    1. Copy the acf-price folder into your wp-content/plugins folder
    2. acf-price 文件夹复制到您的 wp-content / plugins 文件夹

    3. Activate the Price plugin via the plugins admin page
    4. 通过插件管理页面激活价格插件

    5. Create a new field via ACF and select the Price type
    6. 通过ACF创建一个新字段,然后选择“价格”类型

    7. Please refer to the description for more info regarding the field type settings
    8. 有关字段类型设置的更多信息,请参阅说明

下载地址

https://downloads.wordpress.org/plugin/acf-price.1.2.1.zip

https://downloads.wordpress.org/plugin/acf-price.1.2.1.zip

-EOF-

AI助手支持GPT4.0