????

Your IP : 216.73.216.152


Current Path : /home2/morganrand/www/wp-content/themes/wanderfuls/framework/visual-composer/shortcodes/
Upload File :
Current File : /home2/morganrand/www/wp-content/themes/wanderfuls/framework/visual-composer/shortcodes/callout.php

<?php
/**
 * Visual Composer Callout
 *
 * @package Wanderfuls WordPress Theme
 * @subpackage VC Functions
 * @version 3.0.0
 */


/**
 * Register shortcode with VC Composer
 *
 * @since 2.0.0
 */
class WPBakeryShortCode_vcex_callout extends WPBakeryShortCode {
	protected function content( $atts, $content = null ) {
		ob_start();
		include( locate_template( 'vcex_templates/vcex_callout.php' ) );
		return ob_get_clean();
	}
}

/**
 * Adds the shortcode to the Visual Composer
 *
 * @since Wanderfuls 1.4.1
 */
function vcex_callout_vc_map() {
	vc_map( array(
		'name' => __( 'Callout', 'tb' ),
		'description' => __( 'Call to action section with or without button', 'tb' ),
		'base' => 'vcex_callout',
		'icon' => 'vcex-callout vcex-icon fa fa-bullhorn',
		'deprecated' => '3.0.0',
		'category' => TB_THEME_BRANDING,
		'params' => array(
			array(
				'type' => 'textfield',
				'admin_label' => true,
				'heading' => __( 'Unique Id', 'tb' ),
				'description' => __( 'Give your main element a unique ID.', 'tb' ),
				'param_name' => 'unique_id',
			),
			array(
				'type' => 'textfield',
				'admin_label' => true,
				'heading' => __( 'Classes', 'tb' ),
				'description' => __( 'Add additonal classes to the main element.', 'tb' ),
				'param_name' => 'classes',
			),
			array(
				'type' => 'dropdown',
				'heading' => __( 'Visibility', 'tb' ),
				'param_name' => 'visibility',
				'value' => array_flip( tb_visibility() ),
			),
			array(
				'type' => 'dropdown',
				'heading' => __( 'Appear Animation', 'tb' ),
				'param_name' => 'css_animation',
				'value' => array_flip( tb_css_animations() ),
			),
			// Content
			array(
				'type' => 'textarea_html',
				'holder' => 'div',
				'class' => 'vcex-callout',
				'heading' => __( 'Callout Content', 'tb' ),
				'param_name' => 'content',
				'value' => __( 'Enter your content here.', 'tb' ),
				'group' => __( 'Content', 'tb' ),
			),
			// Button
			array(
				'type' => 'textfield',
				'heading' => __( 'URL', 'tb' ),
				'param_name' => 'button_url',
				'group' => __( 'Button', 'tb' ),
			),
			array(
				'type' => 'textfield',
				'heading' => __( 'Text', 'tb' ),
				'param_name' => 'button_text',
				'group' => __( 'Button', 'tb' ),
			),
			array(
				'type' => 'dropdown',
				'heading' => __( 'Button Style', 'tb' ),
				'param_name' => 'button_style',
				'value' => array_flip( tb_button_styles() ),
				'group' => __( 'Button', 'tb' ),
			),
			array(
				'type' => 'dropdown',
				'heading' => __( 'Color', 'tb' ),
				'param_name' => 'button_color',
				'std' => '',
				'value' => array_flip( tb_button_colors() ),
				'group' => __( 'Button', 'tb' ),
			),
			array(
				'type' => 'textfield',
				'heading' => __( 'Border Radius', 'tb' ),
				'param_name' => 'button_border_radius',
				'description' => __( 'Please enter a px value.', 'tb' ),
				'group' => __( 'Button', 'tb' ),
			),
			array(
				'type' => 'dropdown',
				'heading' => __( 'Link Target', 'tb' ),
				'param_name' => 'button_target',
				'value' => array(
					__( 'Self', 'tb' ) => '',
					__( 'Blank', 'tb' ) => 'blank',
				),
				'group' => __( 'Button', 'tb' ),
			),
			array(
				'type' => 'dropdown',
				'heading' => __( 'Rel', 'tb' ),
				'param_name' => 'button_rel',
				'value' => array(
					__( 'None', 'tb' ) => 'none',
					__( 'Nofollow', 'tb' ) => 'nofollow',
				),
				'group' => __( 'Button', 'tb' ),
			),
			array(
				'type' => 'dropdown',
				'heading' => __( 'Icon Left', 'tb' ),
				'param_name' => 'button_icon_left',
				'value' => tb_get_awesome_icons(),
				'group' => __( 'Button', 'tb' ),
			),
			array(
				'type' => 'dropdown',
				'heading' => __( 'Icon Right', 'tb' ),
				'param_name' => 'button_icon_right',
				'value' => tb_get_awesome_icons(),
				'group' => __( 'Button', 'tb' ),
			),
			array(
				'type' => 'css_editor',
				'heading' => __( 'CSS', 'tb' ),
				'param_name' => 'css',
				'group' => __( 'Design options', 'tb' ),
			),
		)
	) );
}
add_action( 'vc_before_init', 'vcex_callout_vc_map' );