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


PHP vc_add_param函数代码示例

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


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

示例1: add_params

 /**
  * Adds new params for the VC Rows
  *
  * @since 2.0.0
  */
 public function add_params()
 {
     /*-----------------------------------------------------------------------------------*/
     /*  - Columns
     			/*-----------------------------------------------------------------------------------*/
     vc_add_param('vc_column', array('type' => 'hidden', 'param_name' => 'style'));
     vc_add_param('vc_column', array('type' => 'dropdown', 'heading' => __('Visibility', 'wpex'), 'param_name' => 'visibility', 'std' => '', 'value' => array_flip(wpex_visibility())));
     vc_add_param('vc_column', array('type' => 'dropdown', 'heading' => __('Animation', 'wpex'), 'param_name' => 'css_animation', 'value' => array_flip(wpex_css_animations())));
     vc_add_param('vc_column', array('type' => 'dropdown', 'heading' => __('Typography Style', 'wpex'), 'param_name' => 'typography_style', 'value' => array_flip(wpex_typography_styles())));
     vc_add_param('vc_column', array('type' => 'textfield', 'heading' => __('Minimum Height', 'wpex'), 'param_name' => 'min_height', 'description' => __('You can enter a minimum height for this row.', 'wpex')));
     // Hidden fields = Deprecated params, these should be removed on save
     $deprecated = array('id', 'typo_style', 'bg_color', 'bg_image', 'bg_style', 'border_style', 'border_color', 'border_width', 'margin_top', 'margin_bottom', 'margin_left', 'padding_top', 'padding_bottom', 'padding_left', 'padding_right', 'drop_shadow');
     foreach ($deprecated as $key => $val) {
         vc_add_param('vc_column', array('type' => 'hidden', 'param_name' => $val));
     }
     /*-----------------------------------------------------------------------------------*/
     /*  - Inner Columns
     			/*-----------------------------------------------------------------------------------*/
     vc_add_param('vc_column_inner', array('type' => 'hidden', 'param_name' => 'style'));
     // Hidden fields = Deprecated params, these should be removed on save
     $deprecated = array('id', 'typo_style', 'bg_color', 'bg_image', 'bg_style', 'border_style', 'border_color', 'border_width', 'margin_top', 'margin_bottom', 'margin_left', 'padding_top', 'padding_bottom', 'padding_left', 'padding_right');
     foreach ($deprecated as $key => $val) {
         vc_add_param('vc_column_inner', array('type' => 'hidden', 'param_name' => $val));
     }
 }
开发者ID:VanessaGarcia-Freelance,项目名称:TheEmporiumGroup,代码行数:30,代码来源:column.php

示例2: webnus_setup_vc_posts_grid

 function webnus_setup_vc_posts_grid()
 {
     vc_remove_param('vc_posts_grid', 'grid_layout');
     $vc_layout_sub_controls = array(array('link_post', __("Link to post", "js_composer")), array("no_link", __("No link", "js_composer")), array("link_image", __("Link to bigger image", "js_composer")));
     $attributes = array("type" => "sorted_list", "heading" => __("Teaser layout", "js_composer"), "param_name" => "grid_layout", "description" => __("Control teasers look. Enable blocks and place them in desired order. Note: This setting can be overrriden on post to post basis.", "js_composer"), "value" => "title,image,text", "options" => array(array('image', __('Thumbnail', "js_composer"), $vc_layout_sub_controls), array('title', __('Title', "js_composer"), $vc_layout_sub_controls), array('text', __('Text', "js_composer"), array(array('excerpt', __('Teaser/Excerpt', "js_composer")), array('text', __('Full content', "js_composer")))), array('meta_author', __('Metadata Author', "js_composer")), array('meta_category', __('Metadata Category', "js_composer")), array('meta_date', __('Metadata Date', "js_composer")), array('meta_comments', __('Metadata Comments', "js_composer"))));
     vc_add_param('vc_posts_grid', $attributes);
 }
开发者ID:bhuvanaurora,项目名称:wordpress-wed,代码行数:7,代码来源:setup_postgrid.php

示例3: add_media_center_vc_params

function add_media_center_vc_params()
{
    // Apply updtes to default VC elements using add param function
    // ===============================================================
    if (function_exists('vc_add_param')) {
        // Add custom row options
        // ===============================================================
        // Add parameters to 'vc_row'
        $base = 'vc_row';
        $extraParams = array(array('type' => 'checkbox', 'param_name' => 'has_container', 'value' => array(__('Has Container ?', 'media_center') => 'true'), 'description' => __('Wrap the row element with container.', 'media_center')), array('type' => 'dropdown', 'heading' => __('Container Class', 'media_center'), 'param_name' => 'container_class', 'value' => array(__('Container', 'media_center') => 'container', __('Container Fluid', 'media_center') => 'container-fluid'), 'description' => __('Specify the class for the container. Will be applied only if has container is set to true.', 'media_center')), array('type' => 'dropdown', 'heading' => __('CSS3 Animation', 'media_center'), 'param_name' => 'row_animation', 'value' => array(__('No Animation', 'media_center') => 'none', __('BounceIn', 'media_center') => 'bounceIn', __('BounceInDown', 'media_center') => 'bounceInDown', __('BounceInLeft', 'media_center') => 'bounceInLeft', __('BounceInRight', 'media_center') => 'bounceInRight', __('BounceInUp', 'media_center') => 'bounceInUp', __('FadeIn', 'media_center') => 'fadeIn', __('FadeInDown', 'media_center') => 'fadeInDown', __('FadeInDown Big', 'media_center') => 'fadeInDownBig', __('FadeInLeft', 'media_center') => 'fadeInLeft', __('FadeInLeft Big', 'media_center') => 'fadeInLeftBig', __('FadeInRight', 'media_center') => 'fadeInRight', __('FadeInRight Big', 'media_center') => 'fadeInRightBig', __('FadeInUp', 'media_center') => 'fadeInUp', __('FadeInUp Big', 'media_center') => 'fadeInUpBig', __('FlipInX', 'media_center') => 'flipInX', __('FlipInY', 'media_center') => 'flipInY', __('Light SpeedIn', 'media_center') => 'lightSpeedIn', __('RotateIn', 'media_center') => 'rotateIn', __('RotateInDown Left', 'media_center') => 'rotateInDownLeft', __('RotateInDown Right', 'media_center') => 'rotateInDownRight', __('RotateInUp Left', 'media_center') => 'rotateInUpLeft', __('RotateInUp Right', 'media_center') => 'rotateInUpRight', __('RoleIn', 'media_center') => 'roleIn', __('ZoomIn', 'media_center') => 'zoomIn', __('ZoomInDown', 'media_center') => 'zoomInDown', __('ZoomInLeft', 'media_center') => 'zoomInLeft', __('ZoomInRight', 'media_center') => 'zoomInRight', __('ZoomInUp', 'media_center') => 'zoomInUp'), 'description' => __('Choose the animation effect on the row when scrolled into view.', 'media_center')));
        foreach ($extraParams as $params) {
            vc_add_param($base, $params);
        }
        // Update 'vc_row' to include custom shortcode template and re-map shortcode
        vc_map_update('vc_row');
        //Add parameters to vc_accordion
        $base = 'vc_accordion';
        $extraParams = array(array('type' => 'dropdown', 'param_name' => 'accordion_style', 'value' => array(__('Style 1', 'media_center') => 'style-1', __('Style 2', 'media_center') => 'style-2')));
        foreach ($extraParams as $params) {
            vc_add_param($base, $params);
        }
        // Update 'vc_row' to include custom shortcode template and re-map shortcode
        vc_map_update('vc_accordion');
    }
}
开发者ID:Qualitair,项目名称:ecommerce,代码行数:25,代码来源:custom_vc.php

示例4: lab_vc_custom_column_params

function lab_vc_custom_column_params()
{
    $laborator_vc_dependency_reveal = array('element' => 'reveal_effect', 'not_empty' => true);
    $params = array('reveal_effect' => array('type' => 'dropdown', 'heading' => __('Reveal Effect', 'lab_composer'), 'param_name' => 'reveal_effect', 'std' => 'none', 'weight' => 3, 'value' => array(__('None', 'lab_composer') => '', __('Fade In', 'lab_composer') => 'fadeIn', __('Slide and Fade', 'lab_composer') => 'fadeInLab', '---------------' => '', __("bounce", 'lab_composer') => 'bounce', __("flash", 'lab_composer') => 'flash', __("pulse", 'lab_composer') => 'pulse', __("rubberBand", 'lab_composer') => 'rubberBand', __("shake", 'lab_composer') => 'shake', __("swing", 'lab_composer') => 'swing', __("tada", 'lab_composer') => 'tada', __("wobble", 'lab_composer') => 'wobble', __("bounceIn", 'lab_composer') => 'bounceIn', __("bounceInDown", 'lab_composer') => 'bounceInDown', __("bounceInLeft", 'lab_composer') => 'bounceInLeft', __("bounceInRight", 'lab_composer') => 'bounceInRight', __("bounceInUp", 'lab_composer') => 'bounceInUp', __("fadeInDown", 'lab_composer') => 'fadeInDown', __("fadeInDownBig", 'lab_composer') => 'fadeInDownBig', __("fadeInLeft", 'lab_composer') => 'fadeInLeft', __("fadeInLeftBig", 'lab_composer') => 'fadeInLeftBig', __("fadeInRight", 'lab_composer') => 'fadeInRight', __("fadeInRightBig", 'lab_composer') => 'fadeInRightBig', __("fadeInUp", 'lab_composer') => 'fadeInUp', __("fadeInUpBig", 'lab_composer') => 'fadeInUpBig', __("flip", 'lab_composer') => 'flip', __("flipInX", 'lab_composer') => 'flipInX', __("flipInY", 'lab_composer') => 'flipInY', __("lightSpeedIn", 'lab_composer') => 'lightSpeedIn', __("rotateIn", 'lab_composer') => 'rotateIn', __("rotateInDownLeft", 'lab_composer') => 'rotateInDownLeft', __("rotateInDownRight", 'lab_composer') => 'rotateInDownRight', __("rotateInUpLeft", 'lab_composer') => 'rotateInUpLeft', __("rotateInUpRight", 'lab_composer') => 'rotateInUpRight', __("hinge", 'lab_composer') => 'hinge', __("rollIn", 'lab_composer') => 'rollIn', __("zoomIn", 'lab_composer') => 'zoomIn', __("zoomInDown", 'lab_composer') => 'zoomInDown', __("zoomInLeft", 'lab_composer') => 'zoomInLeft', __("zoomInRight", 'lab_composer') => 'zoomInRight', __("zoomInUp", 'lab_composer') => 'zoomInUp'), 'description' => __('Set reveal effect for this element. To preview the animations <a href="http://daneden.github.io/animate.css/" target="_blank">click here</a>.', 'lab_composer')), 'reveal_duration' => array('type' => 'textfield', 'heading' => __('Reveal Duration', 'lab_composer'), 'param_name' => 'reveal_duration', 'weight' => 2, 'description' => __('Set number of seconds for the animation duration. (Optional)', 'lab_composer'), 'dependency' => $laborator_vc_dependency_reveal), 'reveal_delay' => array('type' => 'textfield', 'heading' => __('Reveal Delay', 'lab_composer'), 'param_name' => 'reveal_delay', 'weight' => 1, 'description' => __('Set reveal effect delay before showing in seconds, otherwise leave empty.', 'lab_composer'), 'dependency' => $laborator_vc_dependency_reveal));
    vc_add_param('vc_column', $params['reveal_effect']);
    vc_add_param('vc_column', $params['reveal_duration']);
    vc_add_param('vc_column', $params['reveal_delay']);
}
开发者ID:adrienlementheour,项目名称:AliceRouat,代码行数:8,代码来源:custom-columns.php

示例5: something

function something()
{
    $icons = array('type' => 'dropdown', 'heading' => 'Icon library', 'value' => array('Font Awesome' => 'fontawesome', 'Open Iconic' => 'openiconic', 'Typicons' => 'typicons', 'Entypo' => 'entypo', 'Linecons' => 'linecons', 'Pixel' => 'pixelicons', 'Ion icons' => 'ionicons'), 'param_name' => 'i_type', 'description' => 'Select icon library.', 'dependency' => array('element' => 'add_icon', 'value' => 'true'), 'integrated_shortcode' => 'vc_icon', 'integrated_shortcode_field' => 'i_');
    $ionicons = array('type' => 'iconpicker', 'heading' => __('Icon', 'js_composer'), 'param_name' => 'i_icon_ionicons', 'settings' => array('emptyIcon' => false, 'type' => 'ionicons', 'source' => require_once 'ionicons.php'), 'dependency' => array('element' => 'i_type', 'value' => 'ionicons'), 'description' => __('Select icon from library.', 'js_composer'));
    vc_remove_param('vc_btn', 'i_type');
    vc_add_param('vc_btn', $icons);
    vc_add_param('vc_btn', $ionicons);
}
开发者ID:sebjon-bytbil,项目名称:BB.CMS,代码行数:8,代码来源:icons.php

示例6: _adap_sc_add_column_full_width_option

function _adap_sc_add_column_full_width_option()
{
    if (function_exists('wpb_add_param')) {
        wpb_add_param('vc_column', AdapAutoVCShortcode::bool_param('full_width', 'Full Width', 'Make Full Width', 'Don\'t Make Full Width', false));
        wpb_add_param('vc_column', array('type' => 'dropdown', 'heading' => 'Align', 'param_name' => 'align', 'sch_default' => 'align-none', 'value' => array('None' => 'align-none', 'Align Left' => 'align-left', 'Align Center' => 'align-center', 'Align Right' => 'align-right'), 'description' => 'The content alignment of the column'));
        vc_add_param('rev_slider_vc', array('type' => 'dropdown', 'heading' => 'Arrow Style', 'param_name' => 'arrow_style', 'sch_default' => 'small', 'value' => array('Small' => 'small', 'Big' => 'big'), 'description' => 'The arrow styling'));
    }
}
开发者ID:hoonio,项目名称:PhoneAfrika,代码行数:8,代码来源:column.php

示例7: stm_update_existing_shortcodes

function stm_update_existing_shortcodes()
{
    if (function_exists('vc_add_param')) {
        $attributes = array(array('type' => 'css_editor', 'heading' => __('Css', STM_DOMAIN), 'param_name' => 'css', 'group' => __('Design options', STM_DOMAIN)), array('type' => 'dropdown', 'heading' => __('Type', STM_DOMAIN), 'param_name' => 'type', 'value' => array(__('Type 1', STM_DOMAIN) => 'type_1', __('Type 2', STM_DOMAIN) => 'type_2', __('Type 3', STM_DOMAIN) => 'type_3', __('Type 4', STM_DOMAIN) => 'type_4')), array('type' => 'colorpicker', 'heading' => __('Text Color', STM_DOMAIN), 'param_name' => 'text_color'), array('type' => 'vc_link', 'class' => '', 'heading' => __('Link', STM_DOMAIN), 'param_name' => 'link'), array('type' => 'textfield', 'heading' => __('Text Font size (px)', STM_DOMAIN), 'param_name' => 'text_font_size', 'value' => ''));
        vc_add_params('vc_text_separator', $attributes);
        $attributes = array(array('type' => 'css_editor', 'heading' => __('Css', STM_DOMAIN), 'param_name' => 'css', 'group' => __('Design options', STM_DOMAIN)), array('type' => 'textfield', 'heading' => __('Text Font size (px)', STM_DOMAIN), 'param_name' => 'text_font_size', 'group' => __('Design options', STM_DOMAIN), 'value' => 16), array('type' => 'colorpicker', 'heading' => __('Text Color', STM_DOMAIN), 'param_name' => 'text_color', 'group' => __('Design options', STM_DOMAIN)), array('type' => 'textfield', 'heading' => __('Text Margin`s (px)', STM_DOMAIN), 'param_name' => 'text_margins', 'group' => __('Design options', STM_DOMAIN), 'value' => '0px 0px 0px 0px'));
        vc_add_params('vc_cta_button', $attributes);
        $attributes = array('type' => 'css_editor', 'heading' => __('Css', STM_DOMAIN), 'param_name' => 'css', 'group' => __('Design options', STM_DOMAIN));
        vc_add_param('vc_progress_bar', $attributes);
    }
}
开发者ID:bogdandobritoiu,项目名称:aripi,代码行数:11,代码来源:visual_composer.php

示例8: init

 function init()
 {
     vc_add_param("vc_column_text", array("type" => "ivan_customizer", "class" => "", "heading" => __("H1 Customization", 'iv_js_composer'), "param_name" => "h1_css", "customize" => $this->selectors['h1_css'], "value" => "", "group" => __('H1', 'iv_js_composer')));
     vc_add_param("vc_column_text", array("type" => "ivan_customizer", "class" => "", "heading" => __("H2 Customization", 'iv_js_composer'), "param_name" => "h2_css", "customize" => $this->selectors['h2_css'], "value" => "", "group" => __('H2', 'iv_js_composer')));
     vc_add_param("vc_column_text", array("type" => "ivan_customizer", "class" => "", "heading" => __("H3 Customization", 'iv_js_composer'), "param_name" => "h3_css", "customize" => $this->selectors['h3_css'], "value" => "", "group" => __('H3', 'iv_js_composer')));
     vc_add_param("vc_column_text", array("type" => "ivan_customizer", "class" => "", "heading" => __("H4 Customization", 'iv_js_composer'), "param_name" => "h4_css", "customize" => $this->selectors['h4_css'], "value" => "", "group" => __('H4', 'iv_js_composer')));
     vc_add_param("vc_column_text", array("type" => "ivan_customizer", "class" => "", "heading" => __("H5 Customization", 'iv_js_composer'), "param_name" => "h5_css", "customize" => $this->selectors['h5_css'], "value" => "", "group" => __('H5', 'iv_js_composer')));
     vc_add_param("vc_column_text", array("type" => "ivan_customizer", "class" => "", "heading" => __("H6 Customization", 'iv_js_composer'), "param_name" => "h6_css", "customize" => $this->selectors['h6_css'], "value" => "", "group" => __('H6', 'iv_js_composer')));
     vc_add_param("vc_column_text", array("type" => "ivan_customizer", "class" => "", "heading" => __("Paragraph Customization", 'iv_js_composer'), "param_name" => "p_css", "customize" => $this->selectors['p_css'], "value" => "", "group" => __('Paragraph', 'iv_js_composer')));
     vc_add_param("vc_column_text", array("type" => "ivan_customizer", "class" => "", "heading" => __("Link Customization", 'iv_js_composer'), "param_name" => "link_css", "customize" => $this->selectors['link_css'], "value" => "", "group" => __('Link', 'iv_js_composer')));
     vc_add_param("vc_column_text", array("type" => "ivan_customizer", "class" => "", "heading" => __("List Customization", 'iv_js_composer'), "param_name" => "list_css", "customize" => $this->selectors['list_css'], "value" => "", "group" => __('List', 'iv_js_composer')));
 }
开发者ID:baochung26,项目名称:happy-c,代码行数:12,代码来源:text.php

示例9: add_vc_params

 public function add_vc_params()
 {
     foreach (WPBMap::getAllShortCodes() as $base => $element) {
         if (!in_array($base, array_merge($this->settings['support'], array_keys(WPKit::get_shortcodes())))) {
             WPBMap::dropShortcode($base);
         }
     }
     foreach ($this->settings['params'] as $param) {
         foreach ($param['shortcodes'] as $shortcode) {
             vc_add_param($shortcode, $param);
         }
     }
 }
开发者ID:darbymanning,项目名称:Family-Church,代码行数:13,代码来源:JsComposer.php

示例10: add_params

 /**
  * Adds new params for the VC Rows
  *
  * @since 3.0.0
  * @access public
  */
 public function add_params()
 {
     // Get global object
     global $vcex_global;
     vc_add_param('vc_text_separator', array('type' => 'dropdown', 'heading' => __('Element Type', 'wpex'), 'param_name' => 'element_type', 'value' => array('div' => 'div', 'h1' => 'h1', 'h2' => 'h2', 'h3' => 'h3', 'h4' => 'h4', 'h5' => 'h5', 'h6' => 'h6')));
     vc_add_param('vc_text_separator', array('type' => 'dropdown', 'heading' => __('Style', 'wpex'), 'param_name' => 'style', 'value' => array(__('Bottom Border', 'wpex') => 'one', __('Bottom Border With Color', 'wpex') => 'two', __('Line Through', 'wpex') => 'three', __('Double Line Through', 'wpex') => 'four', __('Dotted', 'wpex') => 'five', __('Dashed', 'wpex') => 'six', __('Top & Bottom Borders', 'wpex') => 'seven', __('Graphical', 'wpex') => 'eight', __('Outlined', 'wpex') => 'nine')));
     vc_add_param('vc_text_separator', array('type' => 'colorpicker', 'heading' => __('Border Color', 'wpex'), 'param_name' => 'border_color', 'description' => __('Select a custom color for your colored border under the title.', 'wpex'), 'dependency' => array('element' => 'style', 'value' => array('two'))));
     vc_add_param('vc_text_separator', array('type' => 'textfield', 'heading' => __('Font Size', 'wpex'), 'param_name' => 'font_size', 'description' => __('You can use "em" or "px" values, but you must define them.', 'wpex')));
     vc_add_param('vc_text_separator', array('type' => 'dropdown', 'heading' => __('Font Weight', 'wpex'), 'std' => '', 'param_name' => 'font_weight', 'description' => __('Note: Not all font families support every font weight.', 'wpex'), 'value' => array_flip(wpex_font_weights())));
     vc_add_param('vc_text_separator', array('type' => 'textfield', 'heading' => __('Bottom Margin', 'wpex'), 'param_name' => 'margin_bottom', 'description' => __('Please enter a px value.', 'wpex')));
     vc_add_param('vc_text_separator', array('type' => 'colorpicker', 'heading' => __('Background Color', 'wpex'), 'param_name' => 'span_background', 'dependency' => array('element' => 'style', 'value' => array('three', 'four', 'five', 'six'))));
     vc_add_param('vc_text_separator', array('type' => 'colorpicker', 'heading' => __('Font Color', 'wpex'), 'param_name' => 'span_color'));
 }
开发者ID:VanessaGarcia-Freelance,项目名称:TheEmporiumGroup,代码行数:19,代码来源:text-separator.php

示例11: web_vc_add_attr

function web_vc_add_attr()
{
    /**
     * Add background atrributes to VC Rows
     */
    $attributes = array('type' => 'dropdown', 'heading' => "Background Style", 'param_name' => 'background_style', 'value' => array_flip(array('' => 'Standard Settings', 'full' => 'Fullwidth Section', 'light-wrapper' => 'Light Background', 'dark-wrapper' => 'Dark Background', 'bg-primary' => 'Primary Highlight Colour Background', 'bg-secondary-1' => 'Secondary Highlight Colour Background', 'bg-secondary-2 ' => 'Secondary Highlight 2 Colour Background', 'image' => 'Parallax Background Image (Full Width)', 'image-left' => 'Image Left, Content on Right', 'image-right' => 'Image Right, Content on Left')), 'description' => "Choose Background Style For This Row");
    vc_add_param('vc_row', $attributes);
    /**
     * Add smooth scroll
     */
    $attributes = array('type' => 'textfield', 'heading' => "Single Page Scroll ID", 'param_name' => 'single_link', 'value' => '', 'description' => "Enter a lowercase scroll id to link the menu to, no spaces or special characters.");
    vc_add_param('vc_row', $attributes);
}
开发者ID:WebTM,项目名称:web,代码行数:13,代码来源:vc_functions.php

示例12: add_params

 /**
  * Adds new params for the VC Single_Images
  *
  * @since 2.0.0
  */
 public static function add_params()
 {
     vc_add_param('vc_single_image', array('type' => 'dropdown', 'heading' => esc_html__('Image alignment', 'total'), 'param_name' => 'alignment', 'value' => array(esc_html__('Default', 'total') => '', esc_html__('Left', 'total') => 'left', esc_html__('Right', 'total') => 'right', esc_html__('Center', 'total') => 'center'), 'description' => esc_html__('Select image alignment.', 'total')));
     vc_add_param('vc_single_image', array('type' => 'dropdown', 'heading' => esc_html__('Image Filter', 'total'), 'param_name' => 'img_filter', 'value' => array_flip(wpex_image_filters()), 'description' => esc_html__('Select an image filter style.', 'total')));
     vc_add_param('vc_single_image', array('type' => 'textfield', 'heading' => esc_html__('Over Image Caption', 'total'), 'param_name' => 'img_caption', 'description' => esc_html__('Use this field to add a caption to any single image with a link.', 'total')));
     vc_add_param('vc_single_image', array('type' => 'dropdown', 'heading' => esc_html__('CSS3 Image Link Hover', 'total'), 'param_name' => 'img_hover', 'std' => '', 'value' => array_flip(wpex_image_hovers()), 'description' => esc_html__('Select your preferred image hover effect. Please note this will only work if the image links to a URL or a large version of itself. Please note these effects may not work in all browsers.', 'total')));
     vc_add_param('vc_single_image', array('type' => 'textfield', 'heading' => esc_html__('Video, SWF, Flash, URL Lightbox', 'total'), 'param_name' => 'lightbox_video', 'description' => esc_html__('Enter the URL to a video, SWF file, flash file or a website URL to open in lightbox.', 'total'), 'group' => esc_html__('Custom Lightbox', 'total')));
     vc_add_param('vc_single_image', array('type' => 'dropdown', 'heading' => esc_html__('Lightbox Type', 'total'), 'param_name' => 'lightbox_iframe_type', 'value' => array(esc_html__('Auto Detect', 'total') => '', esc_html__('URL', 'total') => 'url', esc_html__('Youtube, Vimeo, Embed or Iframe', 'total') => 'video_embed', esc_html__('HTML5', 'total') => 'html5', esc_html__('Quicktime', 'total') => 'quicktime'), 'description' => esc_html__('Auto detect depends on the iLightbox API, so by choosing your type it speeds things up and you also allows for HTTPS support.', 'total'), 'group' => esc_html__('Custom Lightbox', 'total'), 'dependency' => array('element' => 'lightbox_video', 'not_empty' => true)));
     vc_add_param('vc_single_image', array('type' => 'textfield', 'heading' => esc_html__('HTML5 Webm URL', 'total'), 'param_name' => 'lightbox_video_html5_webm', 'description' => esc_html__('Enter the URL to a video, SWF file, flash file or a website URL to open in lightbox.', 'total'), 'group' => esc_html__('Custom Lightbox', 'total'), 'dependency' => array('element' => 'lightbox_iframe_type', 'value' => 'html5')));
     vc_add_param('vc_single_image', array('type' => 'textfield', 'heading' => esc_html__('Lightbox Dimensions', 'total'), 'param_name' => 'lightbox_dimensions', 'description' => esc_html__('Enter a custom width and height for your lightbox pop-up window. Use format widthxheight. Example: 900x600.', 'total'), 'group' => esc_html__('Custom Lightbox', 'total')));
     vc_add_param('vc_single_image', array('type' => 'attach_image', 'admin_label' => false, 'heading' => esc_html__('Custom Image Lightbox', 'total'), 'param_name' => 'lightbox_custom_img', 'description' => esc_html__('Select a custom image to open in lightbox format', 'total'), 'group' => esc_html__('Custom Lightbox', 'total')));
     vc_add_param('vc_single_image', array('type' => 'attach_images', 'admin_label' => false, 'heading' => esc_html__('Gallery Lightbox', 'total'), 'param_name' => 'lightbox_gallery', 'description' => esc_html__('Select images to create a lightbox Gallery.', 'total'), 'group' => esc_html__('Custom Lightbox', 'total')));
     // Hidden fields for parsing
     vc_add_param('vc_single_image', array('type' => 'hidden', 'param_name' => 'rounded_image'));
 }
开发者ID:iq007,项目名称:MadScape,代码行数:20,代码来源:single-image.php

示例13: ebor_vc_add_attr

 function ebor_vc_add_attr()
 {
     $attributes = array('type' => 'dropdown', 'heading' => "Section Layout", 'param_name' => 'layout', 'value' => array_flip(array('standard' => 'Standard Row', 'full' => 'Fullwidth Row')), 'description' => "Choose Layout For This Row");
     vc_add_param('vc_row', $attributes);
     /**
      * Add portfolio category selectors
      */
     $portfolio_args = array('orderby' => 'name', 'hide_empty' => 0, 'hierarchical' => 1, 'taxonomy' => 'portfolio_category');
     $portfolio_cats = get_categories($portfolio_args);
     $final_portfolio_cats = array('Show all categories' => 'all');
     foreach ($portfolio_cats as $cat) {
         $final_portfolio_cats[$cat->name] = $cat->term_id;
     }
     $attributes = array('type' => 'dropdown', 'heading' => "Show Specific Portfolio Category?", 'param_name' => 'filter', 'value' => $final_portfolio_cats);
     vc_add_param('huntington_portfolio', $attributes);
 }
开发者ID:anaguerra,项目名称:dombidau,代码行数:16,代码来源:vc_init.php

示例14: mm_vc_custom_component_atts

/**
 * Add shared Mm parameters/atts to all VC components.
 *
 * @since  1.0.0
 */
function mm_vc_custom_component_atts()
{
    // Get all available VC components.
    $components = WPBMap::getShortCodes();
    // Create custom group title.
    $custom_group = __('Mm Custom Settings', 'mm-components');
    // Text color.
    $atts[] = array('type' => 'dropdown', 'heading' => __('Text Color Scheme', 'mm-components'), 'param_name' => 'mm_class_text_color', 'group' => $custom_group, 'value' => array(__('Default', 'mm-components ') => '', __('Dark', 'mm-components ') => 'dark', __('Light', 'mm-components ') => 'light', __('Medium', 'mm-components ') => 'medium'));
    // Text alignment.
    $atts[] = array('type' => 'dropdown', 'heading' => __('Text Alignment', 'mm-components'), 'param_name' => 'mm_class_text_align', 'group' => $custom_group, 'value' => array(__('Default', 'mm-components ') => '', __('Left', 'mm-components ') => 'left', __('Center', 'mm-components ') => 'center', __('Right', 'mm-components ') => 'right'));
    // Custom Class.
    $atts[] = array('type' => 'textfield', 'heading' => __('Custom Class', 'mm-components'), 'param_name' => 'mm_custom_class', 'group' => $custom_group);
    // Add each param to each VC component.
    foreach ($atts as $att) {
        foreach ($components as $component) {
            vc_add_param($component['base'], $att);
        }
    }
}
开发者ID:roosalles,项目名称:mm-components,代码行数:24,代码来源:vc-functions.php

示例15: lab_vc_custom_icon_fonts

function lab_vc_custom_icon_fonts()
{
    # Add Extra Icon Fonts
    $param = WPBMap::getParam('vc_icon', 'type');
    if (!is_array($param)) {
        return false;
    }
    $param['weight'] = 2;
    $param['value'] = array('Linea' => 'linea') + $param['value'];
    vc_update_shortcode_param('vc_icon', $param);
    # Add Param Type
    $attributes = array('type' => 'iconpicker', 'heading' => __('Icon', 'lab_composer'), 'param_name' => 'icon_linea', 'value' => 'icon-basic-accelerator', 'weight' => 1, 'settings' => array('emptyIcon' => false, 'type' => 'linea', 'iconsPerPage' => -1), 'dependency' => array('element' => 'type', 'value' => 'linea'), 'description' => __('Select icon from library.', 'lab_composer'));
    vc_add_param('vc_icon', $attributes);
    # Set Default Color to Black
    $param = WPBMap::getParam('vc_icon', 'color');
    $param['std'] = 'black';
    vc_update_shortcode_param('vc_icon', $param);
    # Custom Icon
    add_action('admin_print_styles', 'lab_vc_custom_icon_css');
}
开发者ID:adrienlementheour,项目名称:AliceRouat,代码行数:20,代码来源:custom-font-icons.php


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