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


PHP acf_add_options_sub_page函数代码示例

本文整理汇总了PHP中acf_add_options_sub_page函数的典型用法代码示例。如果您正苦于以下问题:PHP acf_add_options_sub_page函数的具体用法?PHP acf_add_options_sub_page怎么用?PHP acf_add_options_sub_page使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


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

示例1: setup_settings_page

 public static function setup_settings_page()
 {
     if (function_exists('acf_add_options_page')) {
         acf_add_options_sub_page(array('page_title' => 'Fruit Pack Settings', 'menu_title' => 'Fruit Pack Settings', 'parent_slug' => 'plugins.php'));
     }
     if (function_exists('acf_add_local_field_group')) {
         acf_add_local_field_group(array('key' => 'group_563931a6e6559', 'title' => 'Github Settings', 'fields' => array(array('key' => 'field_563931bfe4a0b', 'label' => 'Github Username', 'name' => 'github_username', 'type' => 'text', 'instructions' => '', 'required' => 0, 'conditional_logic' => 0, 'wrapper' => array('width' => '', 'class' => '', 'id' => ''), 'default_value' => '', 'placeholder' => '', 'prepend' => '', 'append' => '', 'maxlength' => '', 'readonly' => 0, 'disabled' => 0), array('key' => 'field_563931f1e4a0c', 'label' => 'Repository Slug', 'name' => 'repository_slug', 'type' => 'text', 'instructions' => '', 'required' => 0, 'conditional_logic' => 0, 'wrapper' => array('width' => '', 'class' => '', 'id' => ''), 'default_value' => '', 'placeholder' => '', 'prepend' => '', 'append' => '', 'maxlength' => '', 'readonly' => 0, 'disabled' => 0), array('key' => 'field_563931ffe4a0d', 'label' => 'Authorization Key', 'name' => 'authorization_key', 'type' => 'text', 'instructions' => '', 'required' => 0, 'conditional_logic' => 0, 'wrapper' => array('width' => '', 'class' => '', 'id' => ''), 'default_value' => '', 'placeholder' => '', 'prepend' => '', 'append' => '', 'maxlength' => '', 'readonly' => 0, 'disabled' => 0)), 'location' => array(array(array('param' => 'options_page', 'operator' => '==', 'value' => 'acf-options-fruit-pack-settings'))), 'menu_order' => 0, 'position' => 'normal', 'style' => 'default', 'label_placement' => 'top', 'instruction_placement' => 'label', 'hide_on_screen' => ''));
     }
 }
开发者ID:CodeProKid,项目名称:fruitpack,代码行数:9,代码来源:class.fruitpack-admin.php

示例2: plugin_admin_add_page

 /**
  * Register settings page
  */
 function plugin_admin_add_page()
 {
     acf_add_options_page(array('page_title' => 'Brand', 'menu_title' => get_bloginfo('name'), 'menu_slug' => 'theme-general-settings', 'redirect' => false, 'position' => -1));
     acf_add_options_sub_page(array('page_title' => 'SEO (Search Engine Optimization)', 'menu_title' => 'SEO', 'parent_slug' => 'theme-general-settings'));
     acf_add_options_sub_page(array('page_title' => 'SDO (Social Discovery Optimization)', 'menu_title' => 'SDO', 'parent_slug' => 'theme-general-settings'));
     acf_add_options_sub_page(array('page_title' => 'Third Party API\'S', 'menu_title' => 'API\'s', 'parent_slug' => 'theme-general-settings'));
 }
开发者ID:aiganebraska,项目名称:The-Show,代码行数:10,代码来源:conf_post_acf.php

示例3: businesstheme

 function businesstheme()
 {
     // Enable support for Post Thumbnails, and declare two sizes.
     add_theme_support('title-tag');
     add_theme_support('post-thumbnails');
     //set_post_thumbnail_size( 255, 255, true );
     add_image_size('twentyfourteen-full-width', 1038, 576, true);
     add_image_size('service-image', 255, 255, true);
     add_image_size('portfolio-image', 400, 289, true);
     add_image_size('team-image', 235, 235, true);
     add_image_size('about-image', 170, 170, true);
     add_image_size('single', 300, 500);
     // This theme uses wp_nav_menu() in two locations.
     register_nav_menus(array('primary' => __('Primary menu'), 'footer' => __('Footer menu')));
     /*
      * Switch default core markup for search form, comment form, and comments
      * to output valid HTML5.
      */
     add_theme_support('html5', array('search-form', 'comment-form', 'comment-list', 'gallery', 'caption'));
     add_editor_style(array('css/editor-style.css'));
     if (function_exists('acf_add_options_page')) {
         acf_add_options_sub_page('Header');
         acf_add_options_sub_page('Footer');
         acf_add_options_sub_page('Service');
         acf_add_options_sub_page('Portfolio');
         acf_add_options_sub_page('Team');
         acf_add_options_sub_page('about');
     }
     // This theme uses its own gallery styles.
     add_filter('use_default_gallery_style', '__return_false');
 }
开发者ID:jabrankhalil,项目名称:testsite,代码行数:31,代码来源:functions.php

示例4: yb_add_options_page

function yb_add_options_page()
{
    /* create main yb options page */
    acf_add_options_page(array('page_title' => 'yb Site Options', 'menu_title' => 'Site Options', 'menu_slug' => 'yb-options', 'capability' => 'edit_posts', 'redirect' => false));
    /* create settings sub page */
    acf_add_options_sub_page(array('page_title' => 'Miscellaneous', 'menu_title' => 'Miscellaneous', 'parent_slug' => 'yb-options'));
}
开发者ID:shelbyneilsmith,项目名称:yb-theme,代码行数:7,代码来源:functions-options.php

示例5: optionsPage

 function optionsPage()
 {
     if (function_exists('acf_add_options_page')) {
         acf_add_options_page();
         acf_add_options_sub_page(array('page_title' => 'General Settings', 'menu_title' => 'General'));
         acf_add_options_sub_page(array('page_title' => 'Contact Settings', 'menu_title' => 'Contact'));
     }
 }
开发者ID:fuelingtheweb,项目名称:wp-base-theme,代码行数:8,代码来源:Setup.php

示例6: add_theme_acf_options_page

function add_theme_acf_options_page()
{
    if (function_exists('acf_add_options_page')) {
        acf_add_options_page(array('page_title' => 'Site Settings', 'menu_title' => 'Site Settings', 'menu_slug' => 'site-settings', 'capability' => 'edit_posts', 'redirect' => true));
        acf_add_options_sub_page(array('page_title' => 'Above Average Theme Settings', 'menu_title' => 'AA Settings', 'menu_slug' => 'aa-features', 'parent_slug' => 'site-settings'));
        acf_add_options_sub_page(array('page_title' => 'The Kicker Theme Settings', 'menu_title' => 'TK Settings', 'menu_slug' => 'tk-features', 'parent_slug' => 'site-settings'));
    }
}
开发者ID:dleatherman,项目名称:timbangular-js,代码行数:8,代码来源:options.php

示例7: init

 public function init()
 {
     if (!function_exists('acf_add_options_page')) {
         return;
     }
     $options_page = array('page_title' => 'Blunt Gated Content Options', 'menu_title' => 'Options', 'menu_slug' => 'blunt-gated-content-options', 'capability' => 'edit_posts', 'parent_slug' => 'edit.php?post_type=blunt-gated-content', 'autoload' => 'true');
     acf_add_options_sub_page($options_page);
 }
开发者ID:Hube2,项目名称:blunt-gated-content,代码行数:8,代码来源:options-pages.php

示例8: acf_add_options_page

 function acf_add_options_page()
 {
     if (function_exists('acf_add_options_page')) {
         acf_add_options_page(array('menu_title' => 'Theme Options', 'menu_slug' => 'theme-general-settings', 'capability' => 'edit_posts', 'icon_url' => 'dashicons-welcome-write-blog', 'redirect' => true));
         acf_add_options_sub_page(array('page_title' => 'General Settings', 'menu_title' => 'General Settings', 'parent_slug' => 'theme-general-settings'));
         acf_add_options_sub_page(array('page_title' => 'Home Settings', 'menu_title' => 'Home Settings', 'parent_slug' => 'theme-general-settings'));
     }
 }
开发者ID:dungtd91,项目名称:bones,代码行数:8,代码来源:backend.php

示例9: add_options_pages

 /**
  * Add options pages
  *
  */
 function add_options_pages()
 {
     if (function_exists('acf_add_options_page')) {
         //SITE OPTIONS
         acf_add_options_page(array('page_title' => 'About site', 'menu_title' => 'About site', 'menu_slug' => 'theme-options', 'capability' => 'edit_posts', 'redirect' => true));
         acf_add_options_sub_page(array('page_title' => 'Contact info', 'menu_title' => 'Contact info', 'parent_slug' => 'theme-options'));
         acf_add_options_sub_page(array('page_title' => 'Words', 'menu_title' => 'Words', 'parent_slug' => 'theme-options'));
     }
 }
开发者ID:gencagushi,项目名称:tema,代码行数:13,代码来源:class-acf-functions.php

示例10: mtm_options_page

function mtm_options_page()
{
    if (false !== mtm_acf_check()) {
        acf_add_options_page(array('page_title' => 'Theme General Settings', 'menu_title' => 'Theme Settings', 'menu_slug' => 'theme-general-settings', 'capability' => 'edit_posts', 'redirect' => true));
        acf_add_options_sub_page(array('page_title' => 'Theme Header Settings', 'menu_title' => 'Header', 'parent_slug' => 'theme-general-settings'));
        acf_add_options_sub_page(array('page_title' => 'Theme Default Settings', 'menu_title' => 'Defaults', 'parent_slug' => 'theme-general-settings'));
        acf_add_options_sub_page(array('page_title' => 'Theme Footer Settings', 'menu_title' => 'Footer', 'parent_slug' => 'theme-general-settings'));
    }
}
开发者ID:marktimemedia,项目名称:acf-theme-settings,代码行数:9,代码来源:mtm_options_page.php

示例11: add_options_page

 /**
  * Add menu options page
  * @since 0.1.0
  */
 public function add_options_page()
 {
     if (!function_exists('acf_add_options_sub_page')) {
         return;
     }
     $options_page = 'edit.php?post_type=' . $this->post_type;
     if ($this->post_type == 'post') {
         $options_page = 'edit.php';
     }
     $this->options_page = acf_add_options_sub_page(array('page_title' => 'Options', 'menu_title' => 'Options ' . $this->post_type, 'parent_slug' => $options_page, 'menu_slug' => 'acf-seo-' . $this->post_type, 'post_id' => $this->post_type));
 }
开发者ID:bigwing,项目名称:nest-starter-theme,代码行数:15,代码来源:options.php

示例12: theme_acf_options_pages

function theme_acf_options_pages()
{
    if (function_exists('acf_add_options_page')) {
        $parent = acf_add_options_page(array('page_title' => 'Site Settings', 'menu_title' => 'Site Settings', 'redirect' => false));
        acf_add_options_sub_page(array('page_title' => 'Social Settings', 'menu_title' => 'Social', 'parent_slug' => $parent['menu_slug']));
        acf_add_options_sub_page(array('page_title' => 'Signup Settings', 'menu_title' => 'Signup', 'parent_slug' => $parent['menu_slug']));
        acf_add_options_sub_page(array('page_title' => 'Category Card Content', 'menu_title' => 'Category Info Cards', 'parent_slug' => $parent['menu_slug']));
        acf_add_options_sub_page(array('page_title' => 'Sign up Incentive Widget', 'menu_title' => 'Sign up Widget', 'parent_slug' => $parent['menu_slug']));
        acf_add_options_sub_page(array('page_title' => 'MailChimp Settings', 'menu_title' => 'MailChimp', 'parent_slug' => $parent['menu_slug']));
    }
}
开发者ID:saplingdigitalltd,项目名称:thefoodrush,代码行数:11,代码来源:acf-options.php

示例13: add_pages

 public function add_pages()
 {
     if (function_exists('acf_add_options_page')) {
         foreach ($this->pages as $page) {
             if (isset($page['parent_slug'])) {
                 acf_add_options_sub_page($page);
             } else {
                 acf_add_options_page($page);
             }
         }
     }
 }
开发者ID:vincentboiardt,项目名称:wp-theme,代码行数:12,代码来源:AbstractAdmin.php

示例14: businesstheme

 function businesstheme()
 {
     // Enable support for Post Thumbnails, and declare two sizes.
     add_theme_support('title-tag');
     add_theme_support('post-thumbnails');
     //set_post_thumbnail_size( 255, 255, true );
     add_image_size('twentyfourteen-full-width', 1038, 576, true);
     add_image_size('service-image', 255, 255, true);
     add_image_size('portfolio-image', 400, 289, true);
     add_image_size('team-image', 235, 235, false);
     add_image_size('about-image', 170, 170, true);
     add_image_size('single', 300, 500);
     add_image_size('header', 1300, 800, true);
     // This theme uses wp_nav_menu() in two locations.
     register_nav_menus(array('footer' => __('Footer menu'), 'one page site' => __('One page site')));
     /*
      * Switch default core markup for search form, comment form, and comments
      * to output valid HTML5.
      */
     add_theme_support('html5', array('search-form', 'comment-form', 'comment-list', 'gallery', 'caption'));
     add_editor_style(array('css/editor-style.css'));
     if (function_exists('acf_add_options_page')) {
         acf_add_options_sub_page('Header');
         acf_add_options_sub_page('Footer');
         acf_add_options_sub_page('Service');
         acf_add_options_sub_page('e-commerce');
         acf_add_options_sub_page('Team');
         acf_add_options_sub_page('webapplication');
         acf_add_options_sub_page('wordpress');
     }
     function remove_menus()
     {
         //remove_menu_page( 'index.php' );                  //Dashboard
         remove_menu_page('edit.php');
         //Posts
         remove_menu_page('upload.php');
         //Media
         remove_menu_page('edit.php?post_type=page');
         //Pages
         remove_menu_page('edit-comments.php');
         //Comments
         //remove_menu_page( 'themes.php' );                 //Appearance
         //remove_menu_page( 'plugins.php' );                //Plugins
         //remove_menu_page( 'users.php' );                  //Users
         //remove_menu_page( 'tools.php' );                  //Tools
         //remove_menu_page( 'options-general.php' );        //Settings
     }
     add_action('admin_menu', 'remove_menus');
     // This theme uses its own gallery styles.
     add_filter('use_default_gallery_style', '__return_false');
 }
开发者ID:jabrankhalil,项目名称:websolution,代码行数:51,代码来源:theme.php

示例15: pc_setup

function pc_setup()
{
    add_theme_support('title-tag');
    add_theme_support('post-thumbnails');
    set_post_thumbnail_size(100, 75, true);
    add_image_size('client-logos', 208, 98, true);
    register_nav_menus(array('primary' => __('Primary Menu')));
    add_theme_support('html5', array('search-form', 'comment-form', 'comment-list', 'gallery', 'caption'));
    add_editor_style(array('css/editor-style.css'));
    if (function_exists('acf_add_options_page')) {
        acf_add_options_sub_page('Header');
        acf_add_options_sub_page('Footer');
        acf_add_options_sub_page('404');
        acf_add_options_sub_page('Homepage Options');
    }
}
开发者ID:jabrankhalil,项目名称:testsite,代码行数:16,代码来源:functions.php


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