我正在使用Pagelines DMS主题,我想扩展前端管理面板的功能。我为其构建此页面的用户希望能够直接从此页面编辑一些设置,包括站点标题和标语。
概念:
add_filter(\'pl_sorted_settings_array\', \'add_global_panel2\');
function add_global_panel2($settings){
$settings[\'privacy\'] = array(
\'name\' => \'Blog Name\',
\'icon\' => \'icon-eye-open\',
\'opts\' => array(
// Regular Options Engine
array(
\'id\' => \'blogname\',
\'type\' => \'text\',
\'label\' => __(\'blog Name\', \'pagelines\')
),
// Regular Options Engine
array(
\'id\' => \'blogdescription\',
\'type\' => \'text\',
\'label\' => __(\'blog description![enter image description here][1], \'pagelines\')
),
)
);
// Finally we return the new array
return $settings;
}
是否有方法在文本字段中执行此操作(添加自己的网站标题和标语)。例如,单击“发布选项”按钮将其输出到网站前端,并在“WP API设置”>“常规设置”子菜单页中显示更新版本?