当前位置: 首页>>代码示例>>PHP>>正文


PHP ThemeHelper::createTermDictionary方法代码示例

本文整理汇总了PHP中ThemeHelper::createTermDictionary方法的典型用法代码示例。如果您正苦于以下问题:PHP ThemeHelper::createTermDictionary方法的具体用法?PHP ThemeHelper::createTermDictionary怎么用?PHP ThemeHelper::createTermDictionary使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ThemeHelper的用法示例。


在下文中一共展示了ThemeHelper::createTermDictionary方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: adminCreateMetaBoxPage

 function adminCreateMetaBoxPage()
 {
     global $post;
     $data = array();
     $data['option'] = ThemeOption::getPostMeta($post);
     $data['dictionary']['postCategory'] = ThemeHelper::createTermDictionary('category', array(), array(), array(), 'id');
     ThemeHelper::setDefaultOption($data['option'], 'post_category', array());
     $Template = new ThemeTemplate($data, THEME_PATH_TEMPLATE . 'admin/meta_box_page.php');
     echo $Template->output();
 }
开发者ID:annguyenit,项目名称:fable.local,代码行数:10,代码来源:Theme.Page.class.php

示例2: adminCreateMetaBoxGeneral

 function adminCreateMetaBoxGeneral()
 {
     global $post;
     $Menu = new ThemeMenu();
     $WidgetArea = new ThemeWidgetArea();
     $data = array();
     $data['option'] = ThemeOption::getPostMeta($post);
     $data['nonce'] = wp_nonce_field('adminSaveMetaBox', THEME_CONTEXT . '_meta_box_noncename', false, false);
     $data['dictionary']['widgetArea'] = $WidgetArea->getWidgetAreaDictionary();
     $data['dictionary']['widgetAreaLocation'] = $WidgetArea->getWidgetAreaLocationDictionary(false);
     $data['dictionary']['menu'] = $Menu->getMenuDictionary(true, true, false);
     $data['dictionary']['postCategory'] = ThemeHelper::createTermDictionary('category', array(), array(), array(), 'id');
     ThemeHelper::setDefaultOption($data['option'], 'menu_top', -1);
     ThemeHelper::setDefaultOption($data['option'], 'widget_area_sidebar', -1);
     ThemeHelper::setDefaultOption($data['option'], 'widget_area_sidebar_location', -1);
     ThemeHelper::setDefaultOption($data['option'], 'widget_area_footer', -1);
     ThemeHelper::setDefaultOption($data['option'], 'footer_bottom_enable', -1);
     ThemeHelper::setDefaultOption($data['option'], 'page_background_color', '');
     $Template = new ThemeTemplate($data, THEME_PATH_TEMPLATE . 'admin/meta_box_general.php');
     echo $Template->output();
 }
开发者ID:slavai,项目名称:sadick,代码行数:21,代码来源:Theme.class.php

示例3: adminCreateMetaBoxGeneral

 function adminCreateMetaBoxGeneral()
 {
     global $post;
     $Menu = new ThemeMenu();
     $WidgetArea = new ThemeWidgetArea();
     $data = array();
     $data['option'] = ThemeOption::getPostMeta($post);
     $data['nonce'] = wp_nonce_field('adminSaveMetaBox', THEME_CONTEXT . '_meta_box_noncename', false, false);
     $data['dictionary']['widgetArea'] = $WidgetArea->getWidgetAreaDictionary();
     $data['dictionary']['widgetAreaLocation'] = $WidgetArea->getWidgetAreaLocationDictionary(false);
     $data['dictionary']['menu'] = $Menu->getMenuDictionary(true, true, false);
     $data['dictionary']['postCategory'] = ThemeHelper::createTermDictionary('category', array(), array(), array(), 'id');
     $this->setPostMetaDefault($data['option'], 'general');
     $Template = new ThemeTemplate($data, THEME_PATH_TEMPLATE . 'admin/meta_box_general.php');
     echo $Template->output();
 }
开发者ID:phanhoanglong2610,项目名称:anc_gvn,代码行数:16,代码来源:Theme.class.php


注:本文中的ThemeHelper::createTermDictionary方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。