本文整理汇总了PHP中Redux类的典型用法代码示例。如果您正苦于以下问题:PHP Redux类的具体用法?PHP Redux怎么用?PHP Redux使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了Redux类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: array
/**
* ---> SET ARGUMENTS
* All the possible arguments for Redux.
* For full documentation on arguments, please refer to: https://github.com/ReduxFramework/ReduxFramework/wiki/Arguments
* */
$args = array('opt_name' => $opt_name, 'display_name' => 'Vehicle Booking System', 'display_version' => '1.0.0', 'menu_type' => 'submenu', 'allow_sub_menu' => false, 'menu_title' => __('VBS Options', 'vbs'), 'page_title' => __('Vehicle Booking Options', 'vbs'), 'google_api_key' => '', 'google_update_weekly' => false, 'async_typography' => true, 'admin_bar' => false, 'admin_bar_icon' => 'dashicons-portfolio', 'admin_bar_priority' => 50, 'global_variable' => '', 'dev_mode' => false, 'update_notice' => false, 'customizer' => false, 'page_priority' => null, 'page_parent' => 'vbs_admin_menu', 'page_permissions' => 'manage_options', 'menu_icon' => '', 'last_tab' => '', 'page_icon' => 'icon-themes', 'page_slug' => 'vbs_options', 'save_defaults' => true, 'default_show' => false, 'default_mark' => '', 'show_import_export' => true, 'transient_time' => 60 * MINUTE_IN_SECONDS, 'output' => true, 'output_tag' => true, 'database' => '', 'use_cdn' => false, 'hints' => array('icon' => 'fa fa-question', 'icon_position' => 'right', 'icon_color' => 'lightgray', 'icon_size' => 'normal', 'tip_style' => array('color' => 'light', 'shadow' => true, 'rounded' => false, 'style' => ''), 'tip_position' => array('my' => 'top left', 'at' => 'bottom right'), 'tip_effect' => array('show' => array('effect' => 'slide', 'duration' => '500', 'event' => 'mouseover'), 'hide' => array('effect' => 'slide', 'duration' => '500', 'event' => 'click mouseleave'))));
$args['share_icons'][] = array('url' => 'http://www.facebook.com/interactivedes', 'title' => 'Like us on Facebook', 'icon' => 'fa fa-facebook');
$args['share_icons'][] = array('url' => 'http://twitter.com/intera_design', 'title' => 'Follow us on Twitter', 'icon' => 'fa fa-twitter');
$args['share_icons'][] = array('url' => 'http://www.linkedin.com/companies/820832', 'title' => 'Find us on LinkedIn', 'icon' => 'fa fa-linkedin');
$args['share_icons'][] = array('url' => 'http://github.com/gnikolopoulos', 'title' => 'Find us on GitHub', 'icon' => 'fa fa-github');
// Add content after the form.
$args['footer_text'] = __('<p>Development by <a href="http://interactive-design.gr" target="_blank" >Interactive Design | creative studio</a></p>', 'vbs');
Redux::setArgs($opt_name, $args);
/*
* ---> END ARGUMENTS
*/
/*
*
* ---> START SECTIONS
*
*/
Redux::setSection($opt_name, array('title' => __('General', 'vbs'), 'id' => 'opt-general', 'icon' => 'fa fa-cogs', 'fields' => array(array('id' => 'use_base', 'type' => 'switch', 'title' => __('Use base Location', 'vbs'), 'default' => true), array('id' => 'base_location', 'type' => 'text', 'title' => __('Set your base location', 'vbs'), 'default' => 'Pl. Sintagmatos, Athina 105 63, Greece'), array('id' => 'currency_symbol', 'type' => 'text', 'title' => __('Set Currency symbol', 'vbs'), 'default' => '€'))));
Redux::setSection($opt_name, array('title' => __('Styling', 'vbs'), 'id' => 'opt-styling', 'icon' => 'fa fa-paint-brush', 'fields' => array(array('id' => 'form_style', 'type' => 'button_set', 'title' => __('Form Style', 'vbs'), 'options' => array('stacked' => 'Stacked', 'horizontal' => 'Horizontal'), 'default' => 'stacked'))));
Redux::setSection($opt_name, array('title' => __('PayPal', 'vbs'), 'id' => 'opt-paypal', 'icon' => 'fa fa-paypal', 'fields' => array(array('id' => 'paypal_email', 'type' => 'text', 'title' => __('PayPal email', 'vbs'), 'default' => '[email protected]', 'validate' => 'email'), array('id' => 'paypal_mode', 'type' => 'switch', 'title' => __('Sandbox mode', 'vbs'), 'subtitle' => __('Enable PayPal Sandbox mode', 'vbs'), 'default' => true), array('id' => 'business_name', 'type' => 'text', 'title' => __('Will appear on the PayPal form', 'vbs'), 'default' => 'Your Company LLC.'), array('id' => 'currency_code', 'type' => 'text', 'title' => __('Currency', 'vbs'), 'default' => 'USD'), array('id' => 'return_page', 'type' => 'select', 'title' => __('Page to return to after transaction', 'vbs'), 'data' => 'pages'))));
Redux::setSection($opt_name, array('title' => __('Email', 'vbs'), 'id' => 'opt-email', 'icon' => 'fa fa-envelope', 'fields' => array(array('id' => 'default_email', 'type' => 'text', 'title' => __('Email to be used as the From: field', 'vbs'), 'default' => '[email protected]', 'validate' => 'email'), array('id' => 'email_mode', 'type' => 'switch', 'title' => __('Use PHP mailer?', 'vbs'), 'subtitle' => __('Use PHP Mailer instead of wp_mail()', 'vbs'), 'default' => true))));
Redux::setSection($opt_name, array('title' => __('PHP Mailer', 'vbs'), 'desc' => __('Only needed when you don\'t want to use wp_mail()', 'vbs'), 'id' => 'opt-mailer', 'icon' => 'fa fa-paper-plane', 'fields' => array(array('id' => 'smtp_host', 'type' => 'text', 'title' => __('SMTP Host', 'vbs'), 'default' => 'mail.example.com'), array('id' => 'smtp_port', 'type' => 'text', 'title' => __('SMTP Port', 'vbs'), 'default' => '25'), array('id' => 'smtp_auth', 'type' => 'switch', 'title' => __('SMTP requires authentication?', 'vbs'), 'default' => true), array('id' => 'smtp_secure', 'type' => 'radio', 'title' => __('Use SSL/TLS?', 'vbs'), 'options' => array('none' => 'None', 'ssl' => 'Use SSL', 'tls' => 'Use TLS'), 'default' => 'none'), array('id' => 'smtp_login', 'type' => 'password', 'username' => true, 'title' => 'SMTP Account', 'placeholder' => array('username' => 'SMTP username', 'password' => 'SMTP Password')))));
Redux::setSection($opt_name, array('title' => __('Email Template', 'vbs'), 'id' => 'opt-template', 'icon' => 'fa fa-columns', 'fields' => array(array('id' => 'email_logo', 'type' => 'media', 'url' => true, 'title' => __('Logo image', 'vbs'), 'subtitle' => __('140x50px', 'vbs'), 'default' => array('url' => PLUGIN_DIR_URL . 'templates/default/img/logo.jpg')), array('id' => 'email_banner', 'type' => 'media', 'url' => true, 'title' => __('Heading image', 'vbs'), 'subtitle' => __('600x300px', 'vbs'), 'default' => array('url' => PLUGIN_DIR_URL . 'templates/default/img/banner.jpg')), array('id' => 'email_template', 'type' => 'text', 'title' => __('Folder name that contains the mail template', 'vbs'), 'subtitle' => __('Must be under the /templates folder', 'vbs'), 'default' => 'default'), array('id' => 'email_title', 'type' => 'text', 'title' => __('Email title/Subject', 'vbs'), 'default' => 'Your booking details'), array('id' => 'email_heading', 'type' => 'text', 'title' => __('Header text for notification emails', 'vbs'), 'default' => 'Thank you for booking with us!'), array('id' => 'email_intro', 'type' => 'textarea', 'title' => __('Email intro text', 'vbs'), 'subtitle' => __('No HTML allowed', 'vbs'), 'default' => 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod Tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo', 'validate' => 'no_html'))));
Redux::setSection($opt_name, array('title' => __('Social', 'vbs'), 'id' => 'opt-social', 'icon' => 'fa fa-share-alt', 'fields' => array(array('id' => 'facebook_url', 'type' => 'text', 'title' => __('Your Facebook page/profile URL', 'vbs'), 'default' => 'http://facebook.com', 'validate' => 'url'), array('id' => 'linkedin_url', 'type' => 'text', 'title' => __('Your LinkedIn profile URL', 'vbs'), 'default' => 'http://linkedin.com', 'validate' => 'url'), array('id' => 'twitter_url', 'type' => 'text', 'title' => __('Your Twitter profile URL', 'vbs'), 'default' => 'http://twitter.com', 'validate' => 'url'))));
/*
* <--- END SECTIONS
*/
开发者ID:arsen77,项目名称:vehicle-booking-system,代码行数:31,代码来源:admin-config.php
示例2: add_options
static function add_options()
{
$opt_name = "webidia_framework_opts";
$args = array('opt_name' => $opt_name, 'use_cdn' => TRUE, 'display_name' => 'Webidia Framework Options', 'display_version' => FALSE, 'page_title' => 'Webidia Framework Options', 'update_notice' => TRUE, 'intro_text' => '', 'footer_text' => '', 'menu_type' => 'submenu', 'allow_sub_menu' => TRUE, 'menu_title' => 'Options', 'page_parent' => 'webidia-framework', 'customizer' => TRUE, 'admin_bar' => FALSE, 'dev_mode' => FALSE, 'default_mark' => '*', 'hints' => array('icon_position' => 'right', 'icon_color' => 'lightgray', 'icon_size' => 'normal', 'tip_style' => array('color' => 'light'), 'tip_position' => array('my' => 'top left', 'at' => 'bottom right'), 'tip_effect' => array('show' => array('duration' => '500', 'event' => 'mouseover'), 'hide' => array('duration' => '500', 'event' => 'mouseleave unfocus'))), 'output' => TRUE, 'output_tag' => TRUE, 'settings_api' => TRUE, 'cdn_check_time' => '1440', 'compiler' => TRUE, 'page_permissions' => 'manage_options', 'save_defaults' => TRUE, 'show_import_export' => TRUE, 'database' => 'options', 'transient_time' => '3600', 'network_sites' => TRUE);
Redux::setArgs($opt_name, $args);
$tabs = array(array('id' => 'redux-help-tab-1', 'title' => __('Theme Information 1', 'admin_folder'), 'content' => __('<p>This is the tab content, HTML is allowed.</p>', 'admin_folder')), array('id' => 'redux-help-tab-2', 'title' => __('Theme Information 2', 'admin_folder'), 'content' => __('<p>This is the tab content, HTML is allowed.</p>', 'admin_folder')));
Redux::setHelpTab($opt_name, $tabs);
$content = __('<p>This is the sidebar content, HTML is allowed.</p>', 'admin_folder');
Redux::setHelpSidebar($opt_name, $content);
Redux::setSection($opt_name, array('title' => __('Plugins', 'webidia-builder'), 'desc' => '', 'subsection' => false, 'icon' => 'el el-icon-adjust-alt', 'fields' => array(array('id' => 'wf_options_general_basic_smoothscroll', 'type' => 'switch', 'title' => __('Smooth Scroll', 'webidia_framework'), 'subtitle' => __('', 'webidia_framework'), 'default' => true, 'on' => 'Enabled', 'off' => 'Disabled'), array('id' => 'wf_options_general_basic_animations', 'type' => 'switch', 'title' => __('Animations', 'webidia_framework'), 'subtitle' => __('', 'webidia_framework'), 'default' => true, 'on' => 'Enabled', 'off' => 'Disabled'))));
Redux::setSection($opt_name, array('title' => __('Page Builder', 'webidia-builder'), 'desc' => '', 'subsection' => false, 'icon' => 'el el-icon-adjust-alt', 'fields' => array(array('id' => 'disable_spb', 'type' => 'button_set', 'title' => __('Webidia Page Builder', 'webidiaframework'), 'subtitle' => __('Enable/Disable the Webidia Page Builder functionality with this option.', 'webidiaframework'), 'desc' => '', 'options' => array('1' => 'Disabled', '0' => 'Enabled'), 'default' => '0'), array('id' => 'spb-post-types', 'type' => 'select', 'data' => 'post_types', 'multi' => true, 'default' => array('page', 'post', 'portfolio', 'team', 'spb-section'), 'title' => __('Page Builder Post Types', 'webidiaframework'), 'desc' => __('Select here which post types you would like to enable the page builder for.', 'webidiaframework')))));
Redux::setSection($opt_name, array('type' => 'divide', 'id' => 'divide-1'));
Redux::setSection($opt_name, array('title' => __('Webidia Slider', 'webidia-builder'), 'desc' => '', 'subsection' => false, 'icon' => 'el el-icon-website', 'fields' => array(array('id' => 'disable_ss', 'type' => 'button_set', 'title' => __('Webidia Slider', 'webidiaframework'), 'subtitle' => __('Enable/Disable the Webidia Slider functionality with this option.', 'webidiaframework'), 'desc' => '', 'options' => array('1' => 'Disabled', '0' => 'Enabled'), 'default' => '0'))));
Redux::setSection($opt_name, array('type' => 'divide', 'id' => 'divide-2'));
Redux::setSection($opt_name, array('title' => __('Custom Post Types', 'webidia-builder'), 'desc' => '', 'subsection' => false, 'icon' => 'el el-icon-view-mode', 'fields' => array(array('id' => 'cpt-disable', 'type' => 'checkbox', 'title' => __('Disable Custom Post Types', 'webidiaframework'), 'subtitle' => __('You can disable the custom post types used within the theme here, by checking the corresponding box. NOTE: If you do not want to disable any, then make sure none of the boxes are checked.', 'webidiaframework'), 'options' => array('portfolio' => 'Portfolio', 'galleries' => 'Galleries', 'team' => 'Team', 'clients' => 'Clients', 'testimonials' => 'Testimonials', 'directory' => 'Directory', 'faqs' => 'FAQ', 'spb-section' => 'SPB Section'), 'default' => array('portfolio' => '0', 'galleries' => '0', 'team' => '0', 'clients' => '0', 'testimonials' => '0', 'directory' => '0', 'webidia-slider' => '0')))));
Redux::setSection($opt_name, array('type' => 'divide', 'id' => 'divide-3'));
Redux::setSection($opt_name, array('title' => __('Performance', 'webidia-builder'), 'desc' => '', 'subsection' => false, 'icon' => 'el el-icon-fire', 'fields' => array(array('id' => 'enable_min_styles', 'type' => 'button_set', 'title' => __('Load pre-minified stylesheets', 'webidia-builder'), 'subtitle' => __('Enable this option to load pre-minified stlysheets, for faster page speed.', 'webidia-builder'), 'desc' => '', 'options' => array('1' => 'On', '0' => 'Off'), 'default' => '1'), array('id' => 'enable_min_scripts', 'type' => 'button_set', 'title' => __('Load pre-minified scripts', 'webidia-builder'), 'subtitle' => __('Enable this option to load pre-minified scripts, for faster page speed.', 'webidia-builder'), 'desc' => '', 'options' => array('1' => 'On', '0' => 'Off'), 'default' => '1'))));
}
开发者ID:prosatya,项目名称:WF-Gmap,代码行数:18,代码来源:class-webidia-framework-admin-opts.php
示例3: array
/*
* ---> END ARGUMENTS
*/
/*
* ---> START HELP TABS
*/
$tabs = array(array('id' => 'redux-help-tab-1', 'title' => __('Theme Information 1', 'redux-framework-demo'), 'content' => __('<p>This is the tab content, HTML is allowed.</p>', 'redux-framework-demo')), array('id' => 'redux-help-tab-2', 'title' => __('Theme Information 2', 'redux-framework-demo'), 'content' => __('<p>This is the tab content, HTML is allowed.</p>', 'redux-framework-demo')));
Redux::setHelpTab($opt_name, $tabs);
// Set the help sidebar
$content = __('<p>This is the sidebar content, HTML is allowed.</p>', 'redux-framework-demo');
Redux::setHelpSidebar($opt_name, $content);
/*
* <--- END HELP TABS
*/
/*
*
* ---> START SECTIONS
*
*/
/*
As of Redux 3.5+, there is an extensive API. This API can be used in a mix/match mode allowing for
*/
// -> START Basic Fields
Redux::setSection($opt_name, array('title' => __('Basic Field', 'redux-framework-demo'), 'id' => 'basic', 'desc' => __('Basic field with no subsections.', 'redux-framework-demo'), 'icon' => 'el el-home', 'fields' => array(array('id' => 'opt-text', 'type' => 'text', 'title' => __('Example Text', 'redux-framework-demo'), 'desc' => __('Example description.', 'redux-framework-demo'), 'subtitle' => __('Example subtitle.', 'redux-framework-demo'), 'hint' => array('content' => 'This is a <b>hint</b> tool-tip for the text field.<br/><br/>Add any HTML based text you like here.')))));
Redux::setSection($opt_name, array('title' => __('Basic Fields', 'redux-framework-demo'), 'id' => 'basic', 'desc' => __('Basic fields as subsections.', 'redux-framework-demo'), 'icon' => 'el el-home'));
Redux::setSection($opt_name, array('title' => __('Text', 'redux-framework-demo'), 'desc' => __('For full documentation on this field, visit: ', 'redux-framework-demo') . '<a href="//docs.reduxframework.com/core/fields/text/" target="_blank">//docs.reduxframework.com/core/fields/text/</a>', 'id' => 'opt-text-subsection', 'subsection' => true, 'fields' => array(array('id' => 'text-example', 'type' => 'text', 'title' => __('Text Field', 'redux-framework-demo'), 'subtitle' => __('Subtitle', 'redux-framework-demo'), 'desc' => __('Field Description', 'redux-framework-demo'), 'default' => 'Default Text'))));
Redux::setSection($opt_name, array('title' => __('Text Area', 'redux-framework-demo'), 'desc' => __('For full documentation on this field, visit: ', 'redux-framework-demo') . '<a href="//docs.reduxframework.com/core/fields/textarea/" target="_blank">//docs.reduxframework.com/core/fields/textarea/</a>', 'id' => 'opt-textarea-subsection', 'subsection' => true, 'fields' => array(array('id' => 'textarea-example', 'type' => 'textarea', 'title' => __('Text Area Field', 'redux-framework-demo'), 'subtitle' => __('Subtitle', 'redux-framework-demo'), 'desc' => __('Field Description', 'redux-framework-demo'), 'default' => 'Default Text'))));
/*
* <--- END SECTIONS
*/
开发者ID:TeamSubjectMatter,项目名称:juddfoundation,代码行数:31,代码来源:barebones-config.php
示例4: ultra_get_option
* ---> SET ARGUMENTS
* All the possible arguments for Redux.
* For full documentation on arguments, please refer to: https://github.com/ReduxFramework/ReduxFramework/wiki/Arguments
* */
/*ADDED in Ultra Admin - START */
// manageoptions and super admin
$ultraadmin_permissions = ultra_get_option("ultraadmin_plugin_access", "manage_options");
if ($ultraadmin_permissions == "super_admin" && is_super_admin()) {
$ultraadmin_permissions = 'manage_options';
}
// specific user
$ultraadmin_userid = ultra_get_option("ultraadmin_plugin_userid", "");
if ($ultraadmin_permissions == "specific_user" && $ultraadmin_userid == get_current_user_id()) {
$ultraadmin_permissions = 'read';
}
// if plugin is network activated, then hide it from inner sites.
$menu_type = 'menu';
if (!function_exists('is_plugin_active_for_network')) {
require_once ABSPATH . '/wp-admin/includes/plugin.php';
}
// Makes sure the plugin is defined before trying to use it
if (is_plugin_active_for_network('ultra-admin/ultra-core.php')) {
if (!is_main_site()) {
$menu_type = 'hidden';
}
}
/*ADDED in Ultra Admin - END*/
// $theme = wp_get_theme(); // For use with some settings. Not necessary.
$args = array('opt_name' => $manager_option, 'display_name' => 'Quản lý thiết bị phòng thực hành', 'display_version' => '1.0', 'menu_type' => $menu_type, 'allow_sub_menu' => true, 'menu_title' => __('Management', 'redux-framework-ultra-demo'), 'page_title' => __('Management', 'redux-framework-ultra-demo'), 'google_api_key' => '', 'google_update_weekly' => false, 'async_typography' => true, 'admin_bar' => true, 'admin_bar_icon' => 'dashicons-portfolio', 'admin_bar_priority' => 50, 'global_variable' => 'manager_option', 'dev_mode' => false, 'update_notice' => true, 'customizer' => false, 'page_priority' => null, 'page_parent' => 'themes.php', 'page_permissions' => $ultraadmin_permissions, 'menu_icon' => '', 'last_tab' => '', 'page_icon' => 'icon-themes', 'page_slug' => 'manager_control', 'save_defaults' => true, 'default_show' => false, 'default_mark' => '', 'show_import_export' => true, 'transient_time' => 60 * MINUTE_IN_SECONDS, 'output' => true, 'output_tag' => true, 'footer_credit' => ' ', 'database' => '', 'system_info' => false, 'hints' => array('icon' => 'el el-question-sign', 'icon_position' => 'right', 'icon_color' => 'lightgray', 'icon_size' => 'normal', 'tip_style' => array('color' => 'light', 'shadow' => true, 'rounded' => false, 'style' => ''), 'tip_position' => array('my' => 'top left', 'at' => 'bottom right'), 'tip_effect' => array('show' => array('effect' => 'slide', 'duration' => '500', 'event' => 'mouseover'), 'hide' => array('effect' => 'slide', 'duration' => '500', 'event' => 'click mouseleave'))));
Redux::setArgs($manager_option, $args);
开发者ID:khiconit,项目名称:Device-manager,代码行数:30,代码来源:manager.php
示例5: vortex_systen_main_function
function vortex_systen_main_function()
{
if (!function_exists('is_plugin_active')) {
include_once ABSPATH . 'wp-admin/includes/plugin.php';
}
if (class_exists('myCRED_Hook')) {
include plugin_dir_path(__FILE__) . 'mycredcomments.php';
include plugin_dir_path(__FILE__) . 'mycredposts.php';
function vortex_mycred_references_filter($references)
{
$references['vortex_like_posts_mycred_author_content'] = __('Receive like for posts(content author)', 'vortex_system_ld');
$references['vortex_like_posts_mycred_author'] = __('Receive like for posts(like author)', 'vortex_system_ld');
$references['vortex_like_coms_mycred_author_content'] = __('Receive like for comments(content author)', 'vortex_system_ld');
$references['vortex_like_coms_mycred_author'] = __('Receive like for comments(like author)', 'vortex_system_ld');
return $references;
}
add_filter('mycred_all_references', 'vortex_mycred_references_filter');
}
if (function_exists('is_plugin_active')) {
if (is_plugin_active('redux-framework/redux-framework.php')) {
load_plugin_textdomain('vortex_system_ld', FALSE, basename(plugin_dir_path(__FILE__)) . '/languages');
$reduxoption = plugin_dir_path(__FILE__) . 'admin/vortexlikedislike.php';
$reduxframework = plugin_dir_path(plugin_dir_path(__FILE__)) . 'redux-framework/ReduxCore/framework.php';
if (!class_exists('ReduxFramework') && file_exists($reduxframework)) {
include $reduxframework;
}
if (!isset($vortex_like_dislike) && file_exists($reduxoption)) {
include $reduxoption;
}
//donation button
function vortex_system_donation_button()
{
echo '<form style="width:260px;margin:0 auto;" action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="hidden" name="hosted_button_id" value="VVGFFVJSFVZ7S">
<input type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_donateCC_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!">
<img alt="" border="0" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" width="1" height="1">
</form>
';
}
add_action('redux/vortex_like_dislike/panel/before', 'vortex_system_donation_button');
add_action('redux/vortex_like_dislike/panel/after', 'vortex_system_donation_button');
Redux::init('vortex_like_dislike');
global $vortex_like_dislike;
if ($vortex_like_dislike['v-switch-posts'] && isset($vortex_like_dislike['v-switch-posts'])) {
include plugin_dir_path(__FILE__) . 'posts-pages.php';
//load metabox
include plugin_dir_path(__FILE__) . 'metabox.php';
}
if ($vortex_like_dislike['v-switch-comments'] && isset($vortex_like_dislike['v-switch-comments'])) {
include plugin_dir_path(__FILE__) . 'comments.php';
}
//add custom fields when comment is submited
add_action('comment_post', 'vortex_system_add_likes_dislikes_comments');
function vortex_system_add_likes_dislikes_comments($comment_ID)
{
global $vortex_like_dislike;
$likes = 0;
$dislikes = 0;
if (isset($vortex_like_dislike['v_start_comment_like'])) {
$likes = $vortex_like_dislike['v_start_comment_like'];
}
if (isset($vortex_like_dislike['v_start_comment_dislike'])) {
$dislikes = $vortex_like_dislike['v_start_comment_dislike'];
}
add_comment_meta($comment_ID, 'vortex_system_likes', $likes, true);
add_comment_meta($comment_ID, 'vortex_system_dislikes', $dislikes, true);
}
//add custom fields when post is published
add_action('publish_post', 'post_published_notification');
function post_published_notification($ID)
{
global $vortex_like_dislike;
$likes = 0;
$dislikes = 0;
if (isset($vortex_like_dislike['v_start_post_like'])) {
$likes = $vortex_like_dislike['v_start_post_like'];
}
if (isset($vortex_like_dislike['v_start_post_dislike'])) {
$dislikes = $vortex_like_dislike['v_start_post_dislike'];
}
add_post_meta($ID, 'vortex_system_likes', $likes, true);
add_post_meta($ID, 'vortex_system_dislikes', $dislikes, true);
}
}
}
}
开发者ID:kcpt-steven-kohlmeyer,项目名称:rating-system,代码行数:87,代码来源:rating-system.php
示例6: array
<?php
// -> START Basic Fields
Redux::setSection($opt_name, array('title' => __('Pages', 'span'), 'id' => 'pages_options', 'desc' => __('General Options for Pages', 'span'), 'customizer_width' => '400px', 'icon' => 'el el-file'));
global $option_namespace;
$option_namespace = 'pages';
require get_template_directory() . '/admin/parts/_global-options.php';
开发者ID:ebencarljo,项目名称:span,代码行数:7,代码来源:pages.php
示例7: array
<td>activate ShopStyler customizer</td>
</tr>
<tr>
<td>Set Shop as homepage</td>
<td>When enabled will set WordPress homepage to the shop page</td>
</tr>
<tr>
<td>Set Shop as homepage</td>
<td>When enabled will set WordPress homepage to the shop page</td>
</tr>
</table>
', 'shopstyler-plugin')), array('id' => 'redux-help-tab-2', 'title' => __('Shop Page', 'shopstyler-plugin'), 'content' => __('<p>Shop Page settings</p>', 'shopstyler-plugin')), array('id' => 'redux-help-tab-3', 'title' => __('Product Page', 'shopstyler-plugin'), 'content' => __('<p>Product Page settings</p>', 'shopstyler-plugin')), array('id' => 'redux-help-tab-4', 'title' => __('Sidebar', 'shopstyler-plugin'), 'content' => __('<p>Sidebar settings</p>', 'shopstyler-plugin')));
Redux::setHelpTab($opt_name, $tabs);
// Set the help sidebar
$content = __('<p>ShopStyler Documentation</p><a href="http://shopstyler.moodgiver.com/docs"><button>Read</button></a>', 'shopstyler-plugin');
Redux::setHelpSidebar($opt_name, $content);
/*
* <--- END HELP TABS
*/
//load custom palettes
/*
*
* ---> START SECTIONS
*
*/
/*
As of Redux 3.5+, there is an extensive API. This API can be used in a mix/match mode allowing for
*/
/*************************** START SETTINGS
开发者ID:swina,项目名称:ShopStyler-2,代码行数:30,代码来源:shopstyler-options-config.php
示例8: array
<?php
/*
* Header Options
*/
global $opt_name;
Redux::setSection($opt_name, array('title' => __('Header', 'inspiry'), 'id' => 'header-section', 'desc' => __('This section contains options for header.', 'inspiry'), 'fields' => array(array('id' => 'inspiry_header_variation', 'type' => 'image_select', 'title' => __('Header Design Variation', 'inspiry'), 'subtitle' => __('Select the design variation that you want to use for site header.', 'inspiry'), 'options' => array('1' => array('title' => __('1st Variation', 'inspiry'), 'img' => get_template_directory_uri() . '/inc/theme-options/images/header-variation-1.png'), '2' => array('title' => __('2nd Variation', 'inspiry'), 'img' => get_template_directory_uri() . '/inc/theme-options/images/header-variation-2.png')), 'default' => '1'), array('id' => 'inspiry_header_menu_title', 'type' => 'text', 'title' => __('Menu Button Title', 'inspiry'), 'default' => __('Menu', 'inspiry'), 'required' => array('inspiry_header_variation', '=', 1)), array('id' => 'inspiry_favicon', 'type' => 'media', 'url' => false, 'title' => __('Favicon', 'inspiry'), 'subtitle' => __('Upload your website favicon.', 'inspiry')), array('id' => 'inspiry_logo', 'type' => 'media', 'url' => false, 'title' => __('Logo', 'inspiry'), 'subtitle' => __('Upload logo image for your Website. Otherwise site title will be displayed in place of logo.', 'inspiry')), array('id' => 'inspiry_header_phone', 'type' => 'text', 'title' => __('Phone Number', 'inspiry'), 'default' => ''), array('id' => 'inspiry_facebook_url', 'type' => 'text', 'title' => __('Facebook URL', 'inspiry'), 'validate' => 'url', 'default' => ''), array('id' => 'inspiry_twitter_url', 'type' => 'text', 'title' => __('Twitter URL', 'inspiry'), 'validate' => 'url', 'default' => ''), array('id' => 'inspiry_google_url', 'type' => 'text', 'title' => __('Google Plus URL', 'inspiry'), 'validate' => 'url', 'default' => ''), array('id' => 'inspiry_banner_image', 'type' => 'media', 'url' => false, 'title' => __('Banner Image', 'inspiry'), 'desc' => __('Banner image should have minimum width of 2000px and minimum height of 320px.', 'inspiry'), 'subtitle' => __('This banner image will be displayed on all the pages where banner image is not overridden by page specific banner settings.', 'inspiry')), array('id' => 'inspiry_display_wpml_flags', 'type' => 'switch', 'title' => __('WPML Language Switcher Flags', 'inspiry'), 'subtitle' => __('Do you want to display WPML language switcher flags in header top bar ?', 'inspiry'), 'desc' => __('This option only works if WPML plugin is installed.', 'inspiry'), 'default' => 1, 'on' => __('Display', 'inspiry'), 'off' => __('Hide', 'inspiry')), array('id' => 'inspiry_page_loader', 'type' => 'switch', 'title' => __('Page Loader', 'inspiry'), 'desc' => __('You can enable or disable page loader.', 'inspiry'), 'default' => 1, 'on' => __('Enable', 'inspiry'), 'off' => __('Disable', 'inspiry')), array('id' => 'inspiry_page_loader_gif', 'type' => 'media', 'url' => false, 'title' => __('Page Loader Gif', 'inspiry'), 'desc' => __('You can upload your page loader gif here or default one will be displayed.', 'inspiry'), 'required' => array('inspiry_page_loader', '=', 1)), array('id' => 'inspiry_quick_js', 'type' => 'ace_editor', 'title' => __('Quick JavaScript', 'inspiry'), 'desc' => __('You can paste your JavaScript code here.', 'inspiry'), 'mode' => 'javascript', 'theme' => 'chrome'))));
开发者ID:Juni4567,项目名称:mycashflow,代码行数:7,代码来源:header-options.php
示例9: array
Redux::setSection($opt_name, array('title' => __('Section', 'digitalnoir-option'), 'id' => 'presentation-section', 'desc' => __('For full documentation on this field, visit: ', 'digitalnoir-option') . '<a href="http://docs.reduxframework.com/core/fields/section/" target="_blank">http://docs.reduxframework.com/core/fields/section/</a>', 'subsection' => true, 'fields' => array(array('id' => 'section-start', 'type' => 'section', 'title' => __('Section Example', 'digitalnoir-option'), 'subtitle' => __('With the "section" field you can create indented option sections.', 'digitalnoir-option'), 'indent' => true), array('id' => 'section-test', 'type' => 'text', 'title' => __('Field Title', 'digitalnoir-option'), 'subtitle' => __('Field Subtitle', 'digitalnoir-option')), array('id' => 'section-test-media', 'type' => 'media', 'title' => __('Field Title', 'digitalnoir-option'), 'subtitle' => __('Field Subtitle', 'digitalnoir-option')), array('id' => 'section-end', 'type' => 'section', 'indent' => false), array('id' => 'section-info', 'type' => 'info', 'desc' => __('And now you can add more fields below and outside of the indent.', 'digitalnoir-option')))));
Redux::setSection($opt_name, array('id' => 'presentation-divide-sample', 'type' => 'divide'));
// -> START Switch & Button Set
Redux::setSection($opt_name, array('title' => __('Switch & Button Set', 'digitalnoir-option'), 'id' => 'switch_buttonset', 'desc' => __('', 'digitalnoir-option'), 'icon' => 'el el-cogs'));
Redux::setSection($opt_name, array('title' => __('Button Set', 'digitalnoir-option'), 'id' => 'switch_buttonset-set', 'desc' => __('For full documentation on this field, visit: ', 'digitalnoir-option') . '<a href="http://docs.reduxframework.com/core/fields/button-set/" target="_blank">http://docs.reduxframework.com/core/fields/button-set/</a>', 'subsection' => true, 'fields' => array(array('id' => 'opt-button-set', 'type' => 'button_set', 'title' => __('Button Set Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option'), 'options' => array('1' => 'Opt 1', '2' => 'Opt 2', '3' => 'Opt 3'), 'default' => '2'), array('id' => 'opt-button-set-multi', 'type' => 'button_set', 'title' => __('Button Set, Multi Select', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option'), 'multi' => true, 'options' => array('1' => 'Opt 1', '2' => 'Opt 2', '3' => 'Opt 3'), 'default' => array('2', '3')))));
Redux::setSection($opt_name, array('title' => __('Switch', 'digitalnoir-option'), 'id' => 'switch_buttonset-switch', 'desc' => __('For full documentation on this field, visit: ', 'digitalnoir-option') . '<a href="http://docs.reduxframework.com/core/fields/switch/" target="_blank">http://docs.reduxframework.com/core/fields/switch/</a>', 'subsection' => true, 'fields' => array(array('id' => 'switch-on', 'type' => 'switch', 'title' => __('Switch On', 'digitalnoir-option'), 'subtitle' => __('Look, it\'s on!', 'digitalnoir-option'), 'default' => true), array('id' => 'switch-off', 'type' => 'switch', 'title' => __('Switch Off', 'digitalnoir-option'), 'subtitle' => __('Look, it\'s on!', 'digitalnoir-option'), 'default' => false), array('id' => 'switch-parent', 'type' => 'switch', 'title' => __('Switch - Nested Children, Enable to show', 'digitalnoir-option'), 'subtitle' => __('Look, it\'s on! Also hidden child elements!', 'digitalnoir-option'), 'default' => 0, 'on' => 'Enabled', 'off' => 'Disabled'), array('id' => 'switch-child1', 'type' => 'switch', 'required' => array('switch-parent', '=', '1'), 'title' => __('Switch - This and the next switch required for patterns to show', 'digitalnoir-option'), 'subtitle' => __('Also called a "fold" parent.', 'digitalnoir-option'), 'desc' => __('Items set with a fold to this ID will hide unless this is set to the appropriate value.', 'digitalnoir-option'), 'default' => false), array('id' => 'switch-child2', 'type' => 'switch', 'required' => array('switch-parent', '=', '1'), 'title' => __('Switch2 - Enable the above switch and this one for patterns to show', 'digitalnoir-option'), 'subtitle' => __('Also called a "fold" parent.', 'digitalnoir-option'), 'desc' => __('Items set with a fold to this ID will hide unless this is set to the appropriate value.', 'digitalnoir-option'), 'default' => false))));
// -> START Select Fields
Redux::setSection($opt_name, array('title' => __('Select Fields', 'digitalnoir-option'), 'id' => 'select', 'icon' => 'el el-list-alt'));
Redux::setSection($opt_name, array('title' => __('Select', 'digitalnoir-option'), 'id' => 'select-select', 'desc' => __('For full documentation on this field, visit: ', 'digitalnoir-option') . '<a href="http://docs.reduxframework.com/core/fields/select/" target="_blank">http://docs.reduxframework.com/core/fields/select/</a>', 'subsection' => true, 'fields' => array(array('id' => 'opt-select', 'type' => 'select', 'title' => __('Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option'), 'options' => array('1' => 'Opt 1', '2' => 'Opt 2', '3' => 'Opt 3'), 'default' => '2'), array('id' => 'opt-select-stylesheet', 'type' => 'select', 'title' => __('Theme Stylesheet', 'digitalnoir-option'), 'subtitle' => __('Select your themes alternative color scheme.', 'digitalnoir-option'), 'options' => array('default.css' => 'default.css', 'color1.css' => 'color1.css'), 'default' => 'default.css'), array('id' => 'opt-select-optgroup', 'type' => 'select', 'title' => __('Select Option with optgroup', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option'), 'options' => array('Group 1' => array('1' => 'Opt 1', '2' => 'Opt 2', '3' => 'Opt 3'), 'Group 2' => array('4' => 'Opt 4', '5' => 'Opt 5', '6' => 'Opt 6'), '7' => 'Opt 7', '8' => 'Opt 8', '9' => 'Opt 9'), 'default' => '2'), array('id' => 'opt-multi-select', 'type' => 'select', 'multi' => true, 'title' => __('Multi Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option'), 'options' => array('1' => 'Opt 1', '2' => 'Opt 2', '3' => 'Opt 3'), 'default' => array('2', '3')), array('id' => 'opt-info', 'type' => 'info', 'desc' => __('You can easily add a variety of data from WordPress.', 'digitalnoir-option')), array('id' => 'opt-select-categories', 'type' => 'select', 'data' => 'categories', 'title' => __('Categories Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-select-categories-multi', 'type' => 'select', 'data' => 'categories', 'multi' => true, 'title' => __('Categories Multi Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-select-pages', 'type' => 'select', 'data' => 'pages', 'title' => __('Pages Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-multi-select-pages', 'type' => 'select', 'data' => 'pages', 'multi' => true, 'title' => __('Pages Multi Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-select-tags', 'type' => 'select', 'data' => 'tags', 'title' => __('Tags Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-multi-select-tags', 'type' => 'select', 'data' => 'tags', 'multi' => true, 'title' => __('Tags Multi Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-select-menus', 'type' => 'select', 'data' => 'menus', 'title' => __('Menus Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-multi-select-menus', 'type' => 'select', 'data' => 'menu', 'multi' => true, 'title' => __('Menus Multi Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-select-post-type', 'type' => 'select', 'data' => 'post_type', 'title' => __('Post Type Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-multi-select-post-type', 'type' => 'select', 'data' => 'post_type', 'multi' => true, 'title' => __('Post Type Multi Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-multi-select-sortable', 'type' => 'select', 'data' => 'post_type', 'multi' => true, 'sortable' => true, 'title' => __('Post Type Multi Select Option + Sortable', 'digitalnoir-option'), 'subtitle' => __('This field also has sortable enabled!', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-select-posts', 'type' => 'select', 'data' => 'post', 'title' => __('Posts Select Option2', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-multi-select-posts', 'type' => 'select', 'data' => 'post', 'multi' => true, 'title' => __('Posts Multi Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-select-roles', 'type' => 'select', 'data' => 'roles', 'title' => __('User Role Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-select-capabilities', 'type' => 'select', 'data' => 'capabilities', 'multi' => true, 'title' => __('Capabilities Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option')), array('id' => 'opt-select-elusive', 'type' => 'select', 'data' => 'elusive-icons', 'title' => __('Elusive Icons Select Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('Here\'s a list of all the elusive icons by name and icon.', 'digitalnoir-option')))));
Redux::setSection($opt_name, array('title' => __('Image Select', 'digitalnoir-option'), 'id' => 'select-image_select', 'desc' => __('For full documentation on this field, visit: ', 'digitalnoir-option') . '<a href="http://docs.reduxframework.com/core/fields/image-select/" target="_blank">http://docs.reduxframework.com/core/fields/image-select/</a>', 'subsection' => true, 'fields' => array(array('id' => 'opt-image-select-layout', 'type' => 'image_select', 'title' => __('Images Option for Layout', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This uses some of the built in images, you can use them for layout options.', 'digitalnoir-option'), 'options' => array('1' => array('alt' => '1 Column', 'img' => ReduxFramework::$_url . 'assets/img/1col.png'), '2' => array('alt' => '2 Column Left', 'img' => ReduxFramework::$_url . 'assets/img/2cl.png'), '3' => array('alt' => '2 Column Right', 'img' => ReduxFramework::$_url . 'assets/img/2cr.png'), '4' => array('alt' => '3 Column Middle', 'img' => ReduxFramework::$_url . 'assets/img/3cm.png'), '5' => array('alt' => '3 Column Left', 'img' => ReduxFramework::$_url . 'assets/img/3cl.png'), '6' => array('alt' => '3 Column Right', 'img' => ReduxFramework::$_url . 'assets/img/3cr.png')), 'default' => '2'), array('id' => 'opt-image-select', 'type' => 'image_select', 'title' => __('Images Option', 'digitalnoir-option'), 'subtitle' => __('No validation can be done on this field type', 'digitalnoir-option'), 'desc' => __('This is the description field, again good for additional info.', 'digitalnoir-option'), 'options' => array('1' => array('title' => 'Opt 1', 'img' => 'images/align-none.png'), '2' => array('title' => 'Opt 2', 'img' => 'images/align-left.png'), '3' => array('title' => 'Opt 3', 'img' => 'images/align-center.png'), '4' => array('title' => 'Opt 4', 'img' => 'images/align-right.png')), 'default' => '2'), array('id' => 'opt-presets', 'type' => 'image_select', 'presets' => true, 'full_width' => true, 'title' => __('Preset', 'digitalnoir-option'), 'subtitle' => __('This allows you to set a json string or array to override multiple preferences in your theme.', 'digitalnoir-option'), 'default' => 0, 'desc' => __('This allows you to set a json string or array to override multiple preferences in your theme.', 'digitalnoir-option'), 'options' => array('1' => array('alt' => 'Preset 1', 'img' => ReduxFramework::$_url . '../sample/presets/preset1.png', 'presets' => array('switch-on' => 1, 'switch-off' => 1, 'switch-parent' => 1)), '2' => array('alt' => 'Preset 2', 'img' => ReduxFramework::$_url . '../sample/presets/preset2.png', 'presets' => '{"opt-slider-label":"1", "opt-slider-text":"10"}'))))));
Redux::setSection($opt_name, array('title' => __('Select Image', 'digitalnoir-option'), 'id' => 'select-select_image', 'desc' => __('For full documentation on this field, visit: ', 'digitalnoir-option') . '<a href="http://docs.reduxframework.com/core/fields/select-image/" target="_blank">http://docs.reduxframework.com/core/fields/select-image/</a>', 'subsection' => true, 'fields' => array(array('id' => 'opt-select_image', 'type' => 'select_image', 'presets' => true, 'title' => __('Select Image', 'digitalnoir-option'), 'default' => 0, 'options' => array('1' => array('alt' => 'Preset 1', 'img' => ReduxFramework::$_url . '../sample/presets/preset1.png'), '2' => array('alt' => 'Preset 2', 'img' => ReduxFramework::$_url . '../sample/presets/preset2.png'))))));
// -> START Slider / Spinner
Redux::setSection($opt_name, array('title' => __('Slider / Spinner', 'digitalnoir-option'), 'id' => 'slider_spinner', 'desc' => __('', 'digitalnoir-option'), 'icon' => 'el el-adjust-alt'));
Redux::setSection($opt_name, array('title' => __('Slider', 'digitalnoir-option'), 'id' => 'slider_spinner-slider', 'desc' => __('For full documentation on this field, visit: ', 'digitalnoir-option') . '<a href="http://docs.reduxframework.com/core/fields/slider/" target="_blank">http://docs.reduxframework.com/core/fields/slider/</a>', 'fields' => array(array('id' => 'opt-slider-label', 'type' => 'slider', 'title' => __('Slider Example 1', 'digitalnoir-option'), 'subtitle' => __('This slider displays the value as a label.', 'digitalnoir-option'), 'desc' => __('Slider description. Min: 1, max: 500, step: 1, default value: 250', 'digitalnoir-option'), 'default' => 250, 'min' => 1, 'step' => 1, 'max' => 500, 'display_value' => 'label'), array('id' => 'opt-slider-text', 'type' => 'slider', 'title' => __('Slider Example 2 with Steps (5)', 'digitalnoir-option'), 'subtitle' => __('This example displays the value in a text box', 'digitalnoir-option'), 'desc' => __('Slider description. Min: 0, max: 300, step: 5, default value: 75', 'digitalnoir-option'), 'default' => 75, 'min' => 0, 'step' => 5, 'max' => 300, 'display_value' => 'text'), array('id' => 'opt-slider-select', 'type' => 'slider', 'title' => __('Slider Example 3 with two sliders', 'digitalnoir-option'), 'subtitle' => __('This example displays the values in select boxes', 'digitalnoir-option'), 'desc' => __('Slider description. Min: 0, max: 500, step: 5, slider 1 default value: 100, slider 2 default value: 300', 'digitalnoir-option'), 'default' => array(1 => 100, 2 => 300), 'min' => 0, 'step' => 5, 'max' => '500', 'display_value' => 'select', 'handles' => 2), array('id' => 'opt-slider-float', 'type' => 'slider', 'title' => __('Slider Example 4 with float values', 'digitalnoir-option'), 'subtitle' => __('This example displays float values', 'digitalnoir-option'), 'desc' => __('Slider description. Min: 0, max: 1, step: .1, default value: .5', 'digitalnoir-option'), 'default' => 0.5, 'min' => 0, 'step' => 0.1, 'max' => 1, 'resolution' => 0.1, 'display_value' => 'text')), 'subsection' => true));
Redux::setSection($opt_name, array('title' => __('Spinner', 'digitalnoi
|
请发表评论