AI助手支持GPT4.0
This plugin gives you two CMB field types based on the Sorter script:
此插件基于Sorter脚本为您提供了两种CMB字段类型: p>
`tb_sorter` – Select box with with typeahead-style search.
`tb_sorter` –选择带有预输入样式搜索的框。
Example:
示例: p>
$cmb->add_field(array( $ cmb-> add_field(array( 'name' => 'Page Layout', '名称'=>'页面布局', 'id' => $prefix .'id'=> $ prefix。 'ingredients', '配料', 'desc' => 'Select Page Layout', 'desc'=>'选择页面布局', 'type' => 'tb_sorter', '类型'=>'tb_sorter', 'options' => array( '选项'=>数组( 'enabled' => array( '启用'=>数组( 'highlights' => 'Highlights', 'highlights'=>'Highlights', 'slider' => 'Slider', 'slider'=>'Slider', 'staticpage' => 'Static Page', 'staticpage'=>'静态页面', ), ), 'disabled' => array( 'disabled'=>数组( 'services' => 'Services' '服务'=>'服务' ) ) ), ), ));)); pre>Out put输出 h4> get_post_meta(get_the_ID(), '_yourprefix_about_ingredients', true);get_post_meta(get_the_ID(),'_yourprefix_about_ingredients',true); pre>IMPORTANT: The key pair of ‘placebo’ => ‘placebo’ IS NO LONGER REQUIRED.重要提示:不再需要使用“安慰剂” =>“安慰剂”这对密钥。 p>
$cmb->add_field(array( $ cmb-> add_field(array( 'name' => 'Page Layout', '名称'=>'页面布局', 'id' => $prefix .'id'=> $ prefix。 'ingredients', '配料', 'desc' => 'Select Page Layout', 'desc'=>'选择页面布局', 'type' => 'tb_sorter', '类型'=>'tb_sorter', 'options' => array( '选项'=>数组( 'enabled' => array( '启用'=>数组( 'highlights' => 'Highlights', 'highlights'=>'Highlights', 'slider' => 'Slider', 'slider'=>'Slider', 'staticpage' => 'Static Page', 'staticpage'=>'静态页面', ), ), 'disabled' => array( 'disabled'=>数组( 'services' => 'Services' '服务'=>'服务' ) ) ), ), ));));
$cmb->add_field(array(
$ cmb-> add_field(array(
'name' => 'Page Layout',
'名称'=>'页面布局',
'id' => $prefix .
'id'=> $ prefix。
'ingredients',
'配料',
'desc' => 'Select Page Layout',
'desc'=>'选择页面布局',
'type' => 'tb_sorter',
'类型'=>'tb_sorter',
'options' => array(
'选项'=>数组(
'enabled' => array(
'启用'=>数组(
'highlights' => 'Highlights',
'highlights'=>'Highlights',
'slider' => 'Slider',
'slider'=>'Slider',
'staticpage' => 'Static Page',
'staticpage'=>'静态页面',
),
),
'disabled' => array(
'disabled'=>数组(
'services' => 'Services'
'服务'=>'服务'
)
)
));
));
pre>
get_post_meta(get_the_ID(), '_yourprefix_about_ingredients', true);get_post_meta(get_the_ID(),'_yourprefix_about_ingredients',true); pre>IMPORTANT: The key pair of ‘placebo’ => ‘placebo’ IS NO LONGER REQUIRED.重要提示:不再需要使用“安慰剂” =>“安慰剂”这对密钥。 p>
get_post_meta(get_the_ID(), '_yourprefix_about_ingredients', true);get_post_meta(get_the_ID(),'_yourprefix_about_ingredients',true);
get_post_meta(get_the_ID(), '_yourprefix_about_ingredients', true);
get_post_meta(get_the_ID(),'_yourprefix_about_ingredients',true);
IMPORTANT: The key pair of ‘placebo’ => ‘placebo’ IS NO LONGER REQUIRED.
重要提示:不再需要使用“安慰剂” =>“安慰剂”这对密钥。 p>
You can install this field type as you would a WordPress plugin:
您可以像安装WordPress插件一样安装此字段类型: p>
After you call CMB:
致电CMB后: li>
ol>
Add another line to include the cmb-field-sorter.php file.
添加另一行以包含cmb-field-sorter.php文件。
Something like:
像这样的东西:
require_once ‘cmb-field-type-sorter/cmb-field-sorter.php’;
require_once‘cmb-field-type-sorter / cmb-field-sorter.php'; p>
原文出处:http://www.sanshu.cn/a/7675.html
群主管理都是支付大佬