예제 #1
0
function vntd_services_title_config()
{
    global $post;
    if (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE) {
        return $post_id;
    }
    $custom = get_post_custom($post->ID);
    $title = $icon = $desc = '';
    if (isset($custom["title"][0])) {
        $title = $custom["title"][0];
    }
    if (isset($custom["icon"][0])) {
        $icon = $custom["icon"][0];
    }
    if (isset($custom["desc"][0])) {
        $desc = $custom["desc"][0];
    }
    ?>
	<div class="metabox-options form-table fullwidth-metabox image-upload-dep">
		
		<div class="metabox-option">
			<h6><?php 
    _e('Title', 'veented_backend');
    ?>
:</h6>
			<input type="text" name="title" value="<?php 
    echo $title;
    ?>
">
		</div>
		
		<div class="metabox-option">
			<h6><?php 
    _e('Description', 'veented_backend');
    ?>
:</h6>
			<textarea name="desc"><?php 
    echo $desc;
    ?>
</textarea>
		</div>		
		
		<div class="metabox-option">
			<h6><?php 
    _e('Font-Awesome Icon', 'veented_backend');
    ?>
:</h6>
			<?php 
    vntd_create_dropdown('icon', vntd_fontawesome_array(), $icon);
    ?>
		</div>
		
	</div>
<?php 
}
예제 #2
0
function vntd_vc_shortcodes()
{
    // Link Target array
    $target_arr = array(__("Same window", "js_composer") => "_self", __("New window", "js_composer") => "_blank");
    $colors_arr = array(__("Accent Color", "js_composer") => "accent", __("Blue", "js_composer") => "blue", __("Turquoise", "js_composer") => "turquoise", __("Green", "js_composer") => "green", __("Orange", "js_composer") => "orange", __("Red", "js_composer") => "red", __("Dark", "js_composer") => "dark", __("Grey", "js_composer") => "grey", __("Custom Color", "js_composer") => "custom");
    wpb_map(array("name" => __("Portfolio Carousel", "veented_backed"), "base" => "portfolio_carousel", "class" => "font-awesome", "icon" => "fa-briefcase", "controls" => "full", "description" => "Carousel of portfolio posts", "category" => array("Carousels", "Posts"), "params" => array(array("type" => "checkbox", "class" => "hidden-label", "value" => vntd_vc_portfolio_cats(), "heading" => __("Portfolio Categories", "veented_backed"), "param_name" => "cats", "admin_label" => true, "description" => __("Select categories to be displayed in your carousel. Leave blank for all.", "veented_backend")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Number of posts to show", "veented_backed"), "param_name" => "posts_nr", "value" => "6", "description" => __("This is a total number of posts in the carousel.", "veented_backed")))));
    // Blog Carousel
    wpb_map(array("name" => __("Blog Carousel", "veented_backed"), "base" => "blog_carousel", "class" => "font-awesome", "icon" => "fa-book", "controls" => "full", "description" => "Carousel of blog posts", "category" => array("Carousels", "Posts"), "params" => array(array("type" => "checkbox", "class" => "hidden-label", "value" => vntd_vc_blog_cats(), "heading" => __("Blog Categories", "veented_backed"), "param_name" => "cats", "admin_label" => true, "description" => __("Select categories to be displayed in your carousel. Leave blank for all.", "veented_backend")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Number of posts to show", "veented_backed"), "param_name" => "posts_nr", "value" => "6", "description" => __("This is a total number of posts in the carousel.", "veented_backed")))));
    // Testimonials Carousel
    wpb_map(array("name" => __("Testimonials Carousel", "veented_backed"), "base" => "testimonials", "icon" => "fa-comments", "class" => "font-awesome", "category" => array("Carousels"), "description" => "Fancy testimonials", "params" => array(array("type" => "dropdown", "description" => "Choose a style for your testimonials carousel", "class" => "hidden-label", "heading" => __("Testimonials Style", "veented_backed"), "param_name" => "style", "value" => array("Simple" => "simple", "Expanded (client avatar, columned view)" => "expanded"), "admin_label" => true), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Number of posts to show", "veented_backed"), "param_name" => "posts_nr", "value" => "6"))));
    // Logos Carousel
    wpb_map(array("name" => __("Logos Carousel", "veented_backed"), "base" => "logos_carousel", "icon" => "fa-css3", "class" => "font-awesome", "category" => array("Carousels"), "description" => "Carousel of logo images", "params" => array(array('type' => 'attach_images', 'heading' => __('Images', 'js_composer'), 'param_name' => 'images', 'value' => '', 'description' => __('Select images from media library.', 'js_composer')), array('type' => 'dropdown', 'heading' => __('On click', 'js_composer'), 'param_name' => 'onclick', 'value' => array(__('Do nothing', 'js_composer') => 'link_no', __('Open custom link', 'js_composer') => 'custom_link'), 'description' => __('Define action for onclick event if needed.', 'js_composer')), array('type' => 'exploded_textarea', 'heading' => __('Custom links', 'js_composer'), 'param_name' => 'custom_links', 'description' => __('Enter links for each logo here. Divide links with linebreaks (Enter) . ', 'js_composer'), 'dependency' => array('element' => 'onclick', 'value' => array('custom_link'))))));
    // Services Carousel
    wpb_map(array("name" => __("Services Carousel", "veented_backed"), "base" => "services_carousel", "icon" => "fa-wrench", "class" => "font-awesome", "description" => "Carousel of services", "category" => array("Carousels"), "params" => array(array("type" => "textfield", "class" => "hidden-label", "admin_label" => true, "heading" => __("Number of services to show", "veented_backed"), "param_name" => "posts_nr", "value" => "6"))));
    // Video Lightbox
    wpb_map(array("name" => __("Video Lightbox", "veented_backed"), "base" => "video_lightbox", "icon" => "fa-play-circle-o", "category" => array("Media"), "class" => "font-awesome", "description" => "Video in lightbox window", "params" => array(array('type' => 'textfield', 'heading' => __('Video link', 'js_composer'), 'param_name' => 'link', 'admin_label' => true, 'description' => sprintf(__('Link to the video. More about supported formats at %s.', 'js_composer'), '<a href="http://codex.wordpress.org/Embeds#Okay.2C_So_What_Sites_Can_I_Embed_From.3F" target="_blank">WordPress codex page</a>')), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Label", "veented_backed"), "param_name" => "label", "value" => "6", "desc" => 'Text label visible under the Play icon'))));
    // Team Carousel
    wpb_map(array("name" => __("Team Carousel", "veented_backed"), "base" => "team_carousel", "class" => "font-awesome", "icon" => "fa-users", "controls" => "full", "category" => array("Carousels", "Posts"), "description" => "Carousel of your team members", "params" => array(array("type" => "textfield", "class" => "hidden-label", "value" => "", "heading" => __("Team Members ID", "veented_backed"), "param_name" => "ids", "description" => __("Insert IDs of specific team members to be displayed in this carousel. Leave blank to display all", "veented_backend")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Number of posts to show", "veented_backed"), "param_name" => "posts_nr", "value" => "6", "admin_label" => true, "description" => __("Number of team members to be displayed in the carousel.", "veented_backed")), array("type" => "dropdown", "class" => "hidden-label", "heading" => __("Lightbox Window with Member Details", "veented_backed"), "param_name" => "lightbox", "value" => array("Yes" => "yes", "No" => "no"), "description" => __("Disable the '+' icon that launches the lightbox window with the team member details.", "veented_backed")))));
    // Portfolio Grid
    wpb_map(array("name" => __("Portfolio Grid", "veented_backed"), "base" => "portfolio_grid", "class" => "font-awesome", "icon" => "fa-th", "controls" => "full", "category" => array('Posts'), "description" => "Portfolio posts grid", "params" => array(array("type" => "dropdown", "class" => "hidden-label", "heading" => __("Filtering menu", "veented_backed"), "param_name" => "filter", "value" => array("Yes" => "yes", "No" => "no"), "description" => __("Enable or disable the filterable effect.", "veented_backed")), array("type" => "checkbox", "class" => "hidden-label", "value" => vntd_vc_portfolio_cats(), "heading" => __("Portfolio Categories", "veented_backed"), "param_name" => "cats", "description" => __("Select categories to be displayed in the grid. Leave blank to display all.", "veented_backed")), array("type" => "dropdown", "class" => "hidden-label", "heading" => __("Thumbnail Link Type", "veented_backed"), "param_name" => "link_type", "value" => array('Ajax expandable content' => 'ajax', 'Link to individual posts' => 'direct')), array("type" => "dropdown", "class" => "hidden-label", "heading" => __("Thumbnail Spacing", "veented_backed"), "param_name" => "thumb_space", "value" => array("Yes" => "yes", "No" => "no"), "description" => __("Enable or disable the white space between post thumbnails.", "veented_backed")), array("type" => "dropdown", "class" => "hidden-label", "heading" => __("Columns", "veented_backed"), "param_name" => "cols", "value" => array("5", "4"), "description" => __("Number of columns", "veented_backed"), "dependency" => array('element' => "thumb_space", 'value' => array("no"))), array("type" => "dropdown", "class" => "hidden-label", "heading" => __("Thumbnail Size", "veented_backed"), "std" => 'square', "param_name" => "thumb_size", "value" => array("Square" => "square", "Original Aspect Ratio" => "auto"), "description" => __("Portfolio grid thumbnails size.", "veented_backed")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Posts Number", "veented_backed"), "param_name" => "posts_nr", "value" => '', "description" => __("Number of portfolio posts to be displayed. Leave blank for no limit.", "veented_backed")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("See More Link", "veented_backed"), "param_name" => "more_url", "value" => '', "description" => __("Enter the URL of your Portfolio page. If not blank - a big, square PLUS icon will appear under the portfolio grid.", "veented_backed")))));
    // Blog
    //	wpb_map( array(
    //	   "name" => __("Blog", "veented_backed"),
    //	   "base" => "blog",
    //	   "class" => "",
    //	   "icon" => "fa-file-text-o",
    //	   "controls" => "full",
    //	   "category" => "Posts",
    //	   "params" => array(
    //	      array(
    //	         "type" => "checkbox",
    //	         "class" => "hidden-label",
    //	         "value" => vntd_vc_blog_cats(),
    //	         "heading" => __("Blog Categories", "veented_backed"),
    //	         "param_name" => "cats"
    //	      ),
    //	      array(
    //	         "type" => "dropdown",
    //	         "class" => "hidden-label",
    //	         "heading" => __("Layout", "veented_backed"),
    //	         "param_name" => "style",
    //	         "value" => array("Default" => "default","Classic" => "classic","Grid" => "grid"),
    //	         "admin_label" => true
    //	      ),
    //	      array(
    //	         "type" => "dropdown",
    //	         "class" => "hidden-label",
    //	         "heading" => __("Grid columns number", "veented_backed"),
    //	         "param_name" => "grid_columns",
    //	         "value" => array("4","3","2"),
    //	         "dependency" => Array('element' => "style", 'value' => array("grid"))
    //	      ),
    //	      array(
    //	         "type" => "textfield",
    //	         "class" => "hidden-label",
    //	         "heading" => __("Posts per page", "veented_backed"),
    //	         "param_name" => "posts_nr",
    //	         "value" => '',
    //	      )
    //	   )
    //	));
    // Icon Box
    wpb_map(array("name" => __("Icon Box", "veented_backed"), "base" => "icon_box", "class" => "font-awesome", "icon" => "fa-check-circle-o", "controls" => "full", "category" => 'Content', "description" => "Text with an icon", "params" => array(array("type" => "textfield", "class" => "hidden-label", "heading" => __("Title", "veented_backed"), "param_name" => "title", "holder" => "h4", "value" => ''), array("type" => "textarea", "class" => "hidden-label", "heading" => __("Text Content", "veented_backed"), "param_name" => "text", "holder" => "span", "value" => ''), array("type" => "textfield", "heading" => __("URL (Link)", "js_composer"), "param_name" => "url", "description" => __("Optional icon link.", "js_composer")), array("type" => "textfield", "heading" => __("Link Title", "js_composer"), "param_name" => "link_title", "value" => 'More Info', "dependency" => array('element' => "url", 'not_empty' => true)), array("type" => "dropdown", "heading" => __("Target", "js_composer"), "param_name" => "target", "value" => $target_arr, "dependency" => array('element' => "url", 'not_empty' => true)), array("type" => "dropdown", "class" => "hidden-label", "heading" => __("Style", "veented_backed"), "param_name" => "style", "value" => array('Default (Aligned Left)' => 'default', 'Big Centered' => 'centered', 'Aligned Left 2' => 'left', 'Aligned Right 2' => 'right')), array("type" => "dropdown", "heading" => __("Animated", "js_composer"), "param_name" => "animated", "value" => array("Yes" => "yes", "No" => "no"), "description" => "Enable the element fade in animation on scroll"), array("type" => "textfield", "heading" => __("Animation Delay", "js_composer"), "param_name" => "animation_delay", "value" => '100', "description" => "Fade in animation delay. Can be used to create a nice delay effect if multiple elements of same type.", "dependency" => array('element' => "animated", 'value' => 'yes')), array("type" => "checkbox", "class" => "radio-checkboxes", "heading" => __("Icon", "js_composer"), "param_name" => "icon", "value" => vntd_fontawesome_array()), array("type" => "init_icons"))));
    // Google Map
    wpb_map(array("name" => __("Google Map", "veented_backend"), "base" => "gmap", "icon" => "icon-wpb-map-pin", "category" => 'Content', "description" => "Map block", "params" => array(array("type" => "textfield", "class" => "hidden-label", "heading" => __("Location Latitude", "veented_backed"), "param_name" => "lat", "value" => '41.862274', "description" => __("Please insert the map address latitude if you have problems displaying it. Helpful site: <a target='_blank' href='http://www.latlong.net/'>http://www.latlong.net/</a>", "veented_backed")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Location Longitude", "veented_backed"), "param_name" => "long", "value" => '-87.701328', "description" => __("Please insert the map address longitude value.", "veented_backed")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Map Height", "veented_backed"), "param_name" => "height", "value" => '400', "description" => __("Height of the map element in pixels.", "veented_backed")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Map Zoom", "veented_backed"), "param_name" => "zoom", "value" => '15', "description" => __("Choose the map zoom. Default value: 15", "veented_backed")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Marker 1 Title", "veented_backed"), "param_name" => "marker1_title", "value" => 'Office 1', "description" => __("Marker 1 Title.", "veented_backed")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Marker 1 Text", "veented_backed"), "param_name" => "marker1_text", "value" => 'Your description goes here.', "description" => __("Marker 1 description text.", "veented_backed")), array("type" => "dropdown", "heading" => __("Marker 1 Location", "js_composer"), "param_name" => "marker1_location", "value" => array(__("Map Center", "js_composer") => "center", __("Custom", "js_composer") => "custom"), "description" => __("The first marker location", "js_composer")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Marker 1 Custom Location", "veented_backed"), "param_name" => "marker1_location_custom", "value" => '441.863774,-87.721328', "description" => __("Marker 1 custom location in latitude,longitude format.", "veented_backed")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Marker 2 Title", "veented_backed"), "param_name" => "marker2_title", "value" => '', "description" => __("Marker 2 Title.", "veented_backed")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Marker 2 Text", "veented_backed"), "param_name" => "marker2_text", "value" => 'My secondary marker description.', "dependency" => array('element' => "marker2_title", 'not_empty' => true), "description" => __("Marker 2 description text.", "veented_backed")), array("type" => "textfield", "class" => "hidden-label", "heading" => __("Marker 2 Custom Location", "veented_backed"), "param_name" => "marker2_location", "value" => '41.858774,-87.685328', "dependency" => array('element' => "marker2_title", 'not_empty' => true), "description" => __("Marker 2 location in latitude,longitude format.", "veented_backed")))));
    vc_map(array("name" => __("Button", "js_composer"), "base" => "button", "class" => "no-padding", "icon" => "icon-wpb-ui-button", "category" => 'Content', "description" => "Simple button", "params" => array(array("type" => "textfield", "heading" => __("Text on the button", "js_composer"), "holder" => "button", "class" => "button", "param_name" => "label", "value" => __("Text on the button", "js_composer"), "description" => __("Text on the button.", "js_composer")), array("type" => "textfield", "heading" => __("URL (Link)", "js_composer"), "param_name" => "url", "description" => __("Button link.", "js_composer")), array("type" => "dropdown", "heading" => __("Target", "js_composer"), "param_name" => "target", "value" => $target_arr, "dependency" => array('element' => "url", 'not_empty' => true)), array("type" => "dropdown", "heading" => __("Button color", "js_composer"), "param_name" => "color", "class" => "hidden-label", "value" => $colors_arr, "description" => __("Select button color.", "js_composer")), array("type" => "colorpicker", "heading" => __("Button custom color", "js_composer"), "param_name" => "customcolor", "class" => "hidden-label", "description" => __("Select custom color for your button.", "js_composer"), "dependency" => array('element' => "color", 'value' => array('custom'))), array("type" => "dropdown", "heading" => __("Size", "js_composer"), "param_name" => "size", "class" => "hidden-label", "value" => array(__("Regular size", "js_composer") => "regular", __("Large", "js_composer") => "large", __("Small", "js_composer") => "small"), "description" => __("Button size.", "js_composer")), array("type" => "dropdown", "heading" => __("Button Align", "js_composer"), "param_name" => "align", "value" => array(__("Left", "js_composer") => "", __("Centered", "js_composer") => "center"), "description" => __("Button align.", "js_composer")), array("type" => "init_icons"), array("type" => "textfield", "heading" => __("Margin Top", "js_composer"), "param_name" => "margin_top", "description" => __("Change button's top margin value. Default value: 0px", "js_composer")), array("type" => "textfield", "heading" => __("Margin Bottom", "js_composer"), "param_name" => "margin_bottom", "description" => __("Change button's bottom margin value. Default value: 20px", "js_composer")))));
    // Special Heading
    wpb_map(array("name" => __("Special Heading", "vntd_backend"), "base" => "special_heading", "class" => "no-icon", "icon" => "fa-header", "description" => "Centered heading text", "category" => 'Content', "params" => array(array("type" => "textfield", "heading" => __("Title", 'veented_backend'), "param_name" => "title", "holder" => "h5", "description" => __("Main heading text.", 'veented_backend'), "value" => "This is a Special Heading"), array("type" => "textfield", "heading" => __("Subtitle", 'veented_backend'), "param_name" => "subtitle", "holder" => "span", "description" => __("Smaller text visible below the Main one.", 'veented_backend'), "value" => "Isn't it awesome?"), array("type" => "dropdown", "heading" => __("Animation", "js_composer"), "param_name" => "animated", "class" => "hidden-label", "value" => array(__("Yes", "js_composer") => "yes", __("No", "js_composer") => "no"), "description" => __("Enable the fade-in animation of the heading elements on site scroll.", "js_composer")), array("type" => "dropdown", "class" => "hidden-label", "heading" => __("Title Font", "veented_backed"), "param_name" => "font", "value" => array('Primary' => '', 'Secondary' => 'secondary')), array("type" => "textfield", "heading" => __("Margin Bottom", "js_composer"), "param_name" => "margin_bottom", "class" => "hidden-label", "value" => '30', "description" => __("Bottom margin of the heading section, given in pixels. Default: 30", "js_composer")))));
    // Callout Box
    wpb_map(array("name" => __("Callout Box", "vntd_backend"), "base" => "callout_box", "class" => "font-awesome", "icon" => "fa-align-left", "category" => 'Content', "description" => "Nice blockquote", "params" => array(array("type" => "textfield", "heading" => __("Title", 'veented_backend'), "param_name" => "title", "holder" => "h3", "description" => __("Main heading text.", 'veented_backend'), "value" => "Callout"), array("type" => "textfield", "heading" => __("Subtitle", 'veented_backend'), "param_name" => "subtitle", "holder" => "span", "description" => __("Smaller text visible below the Main one.", 'veented_backend'), "value" => "Callout Box subtitle"))));
    //if(get_post_type($post_id) == 'portfolio') {
    wpb_map(array("name" => __("Portfolio Post Details", "vntd_backend"), "base" => "portfolio_details", "class" => "font-awesome", "icon" => "fa-suitcase", "description" => "Single portfolio post details", "category" => 'Content', "params" => array(array("type" => "dropdown", "class" => "hidden-label", "heading" => __("Style", "veented_backed"), "param_name" => "style", "value" => array('Style 1 (split in two columns)' => 'style2', 'Style 2' => 'style1')), array("type" => "textfield", "heading" => __("Title", 'veented_backend'), "param_name" => "title", "holder" => "h2", "description" => __("Main heading text.", 'veented_backend'), "value" => "Project Details"), array("type" => "textarea_html", "heading" => __("Text Content", 'veented_backend'), "param_name" => "content", "holder" => "div", "description" => __("Smaller text visible below the Main one.", 'veented_backend'), "value" => "Contrary to popular belief, Lorem Ipsum is not simply random text. It has rootsin piece of classical Latin literature from old. Richard McClintock, a Latin profes sor at Hampden-Sydney College in Virginia, looked up."), array("type" => "textfield", "heading" => __("Secondary Title", 'veented_backend'), "param_name" => "title2", "holder" => "h2", "description" => __("Secondary Title", 'veented_backend'), "value" => "Project Description", "dependency" => array('element' => "style", 'value' => array('style2'))), array("type" => "textfield", "heading" => __("Client Name", 'veented_backend'), "param_name" => "client", "holder" => "p", "description" => __("Your project client name.", 'veented_backend'), "value" => "Gold Eye Themes"), array("type" => "exploded_textarea", "heading" => __("Skills", "js_composer"), "param_name" => "skills", "holder" => "p", "value" => 'Design,Photography,HTML,jQuery', "description" => __('Enter the projects skills here. Divide each feature with linebreaks (Enter).', 'js_composer')), array("type" => "textfield", "heading" => __("Client Website", 'veented_backend'), "param_name" => "client_website", "description" => __("Your project client's website. Leave blank to hide.", 'veented_backend'), "value" => ""), array("type" => "textfield", "heading" => __("Button1 Label", 'veented_backend'), "param_name" => "button1_label", "description" => __("Primary button label.", 'veented_backend'), "value" => "Live Preview"), array("type" => "textfield", "heading" => __("Button1 URL", 'veented_backend'), "param_name" => "button1_url", "description" => __("Primary button URL.", 'veented_backend'), "value" => "http://", 'dependency' => array('element' => "button1_label", 'not_empty' => true)), array("type" => "textfield", "heading" => __("Button2 Label", 'veented_backend'), "param_name" => "button2_label", "description" => __("Primary button label.", 'veented_backend'), "value" => ""), array("type" => "textfield", "heading" => __("Button2 URL", 'veented_backend'), "param_name" => "button2_url", "description" => __("Secondary button URL.", 'veented_backend'), "value" => "http://", 'dependency' => array('element' => "button1_label", 'not_empty' => true)))));
    //}
    // Fancy Block
    wpb_map(array("name" => __("Fancy Text Block", "vntd_backend"), "base" => "fancy_text_block", "class" => "font-awesome", "icon" => "fa-list-alt", "category" => 'Content', "description" => "Eye-catching block of text", "params" => array(array("type" => "dropdown", "heading" => __("Style", "js_composer"), "param_name" => "style", "class" => "hidden-label", "value" => array("Style 1" => "style1", "Style 2 (Transparent Background)" => "style2", "Style 3 (Centered)" => "style3"), "description" => __("Enable the fade-in animation of the heading elements on site scroll.", "js_composer")), array("type" => "textfield", "heading" => __("Title", 'veented_backend'), "param_name" => "title", "holder" => "h2", "description" => __("Main heading text.", 'veented_backend'), "value" => "Fancy Title"), array("type" => "textfield", "heading" => __("Subtitle", 'veented_backend'), "param_name" => "subtitle", "holder" => "h4", "description" => __("Smaller text visible below the Main one.", 'veented_backend'), "value" => "Fancy Block subtitle"), array("type" => "textfield", "heading" => __("Alt Title", 'veented_backend'), "param_name" => "alttitle", "description" => __("Medium text visible above the Main one.", 'veented_backend'), "value" => "#01"), array("type" => "textarea", "heading" => __("Text Content", 'veented_backend'), "param_name" => "text", "description" => __("Fancy Text Block content.", 'veented_backend'), "value" => "Text content"), array("type" => "textfield", "heading" => __("Button Label", 'veented_backend'), "param_name" => "button_label", "description" => __("Button Label.", 'veented_backend'), "value" => "Continue"), array("type" => "textfield", "heading" => __("Button URL", 'veented_backend'), "param_name" => "button_url", "description" => __("Button URL.", 'veented_backend'), "value" => "#"), array("type" => "textfield", "heading" => __("Plus Icon URL", 'veented_backend'), "param_name" => "plus_url", "description" => __("URL for the big, PLUS icon. Leave blank to hide the icon.", 'veented_backend'), "value" => ""))));
    // Social Icons
    $social_icons_param = array("type" => "dropdown", "heading" => __("Style", "js_composer"), "param_name" => "style", "class" => "hidden-label", "value" => array("Square" => "square", "Round" => "round"), "description" => __("Social icons style.", "js_composer"));
    $social_icons_params_arr[] = $social_icons_param;
    $social_icons = array('mail' => "E-Mail", 'facebook', 'twitter', 'instagram', 'mail' => "E-Mail", 'tumblr', 'linkedin', 'youtube' => 'YouTube', 'vimeo', 'skype', 'google_plus' => 'Google Plus', 'flickr', 'dropbox', 'pinterest', 'dribbble', 'rss');
    $icon_key = '';
    foreach ($social_icons as $social_icon_key => $social_icon_name) {
        $icon_key = $social_icon_key;
        if (is_numeric($social_icon_key)) {
            $icon_key = $social_icon_name;
        }
        //echo 'NAME: '.$social_icon_name.' KEY: '.$social_icon_key .'|  ';
        $social_icons_params_arr[] = array("type" => "textfield", "heading" => ucfirst($social_icon_name), "param_name" => $icon_key, "holder" => "h5", "description" => ucfirst($social_icon_name) . ' social site URL.');
    }
    wpb_map(array("name" => __("Social Icons", "vntd_backend"), "base" => "social_icons", "class" => "font-awesome", "icon" => "fa-twitter", "category" => 'Content', "description" => "List of social icons", "params" => $social_icons_params_arr));
    // Simple Contact Form
    include_once ABSPATH . 'wp-admin/includes/plugin.php';
    // Require plugin.php to use is_plugin_active() below
    if (is_plugin_active('contact-form-7/wp-contact-form-7.php')) {
        vc_remove_element('contact-form-7');
        global $wpdb;
        $cf7 = $wpdb->get_results("\n\t    SELECT ID, post_title\n\t    FROM {$wpdb->posts}\n\t    WHERE post_type = 'wpcf7_contact_form'\n\t    ");
        $contact_forms = array();
        if ($cf7) {
            foreach ($cf7 as $cform) {
                $contact_forms[$cform->post_title] = $cform->ID;
            }
        } else {
            $contact_forms["No contact forms found"] = 0;
        }
        vc_map(array("base" => "vntd_contact_form", "name" => __("Contact Form 7", "js_composer"), "icon" => "icon-wpb-contactform7", "category" => __('Content', 'js_composer'), "description" => __('Place Contact Form7', 'js_composer'), "params" => array(array("type" => "dropdown", "heading" => __("Select contact form", "js_composer"), "param_name" => "id", "admin_label" => true, "value" => $contact_forms, "description" => __("Choose previously created Contact Form 7 form from the drop down list.", "js_composer")), array("type" => "dropdown", "heading" => __("Animated", "js_composer"), "param_name" => "animated", "value" => array("No" => "no", "Yes" => "no"), "description" => __("Enable fade in animation on scroll", "js_composer")))));
    }
    // if contact form7 plugin active
    // Contact Block
    wpb_map(array("name" => __("Contact Block", "vntd_backend"), "base" => "contact_block", "class" => "font-awesome", "icon" => "fa-envelope-square", "description" => "Show off your contact data", "category" => 'Content', "params" => array(array("type" => "textfield", "heading" => __("Phone Number", 'veented_backend'), "param_name" => "phone", "holder" => "div", "description" => __("Your phone number.", 'veented_backend'), "value" => "0123 456 789"), array("type" => "textfield", "heading" => __("Address", 'veented_backend'), "param_name" => "address", "holder" => "div", "description" => __("Your address.", 'veented_backend'), "value" => "North, Street Name 6901, Melbourne Australia"), array("type" => "textfield", "heading" => __("E-Mail", 'veented_backend'), "param_name" => "email", "holder" => "div", "description" => __("Your e-mail address.", 'veented_backend'), "value" => "*****@*****.**"), array("type" => "textfield", "heading" => __("Facebook", 'veented_backend'), "param_name" => "facebook", "description" => __("Social site URL (optional).", 'veented_backend'), "value" => "http://www.facebook.com"), array("type" => "textfield", "heading" => __("Twitter", 'veented_backend'), "param_name" => "twitter", "description" => __("Social site URL (optional).", 'veented_backend')), array("type" => "textfield", "heading" => __("Google+", 'veented_backend'), "param_name" => "googleplus", "description" => __("Social site URL (optional).", 'veented_backend')), array("type" => "textfield", "heading" => __("Tumblr", 'veented_backend'), "param_name" => "tumblr", "description" => __("Social site URL (optional).", 'veented_backend')), array("type" => "textfield", "heading" => __("Pinterest", 'veented_backend'), "param_name" => "pinterest", "description" => __("Social site URL (optional).", 'veented_backend')), array("type" => "textfield", "heading" => __("LinkedIn", 'veented_backend'), "param_name" => "linkedin", "description" => __("Social site URL (optional).", 'veented_backend')), array("type" => "textfield", "heading" => __("Dribbble", 'veented_backend'), "param_name" => "dribbble", "description" => __("Social site URL (optional).", 'veented_backend')), array("type" => "textfield", "heading" => __("Instagram", 'veented_backend'), "param_name" => "instagram", "description" => __("Social site URL (optional).", 'veented_backend')), array("type" => "textfield", "heading" => __("YouTube", 'veented_backend'), "param_name" => "youtube", "description" => __("Social site URL (optional).", 'veented_backend')))));
    // Call to Action
    wpb_map(array("name" => __("Call to Action", "veented_backend"), "base" => "cta", "class" => "", "icon" => "icon-wpb-call-to-action", "controls" => "edit_popup_delete", "category" => 'Content', "description" => "Heading text with buttons", "params" => array(array("type" => "textarea", "heading" => __("Heading", 'veented_backend'), "param_name" => "heading", "value" => "", "description" => __("Enter your Call to Action Heading", 'veented_backend'), "admin_label" => true), array("type" => "textarea", "heading" => __("Subtitle", 'veented_backend'), "param_name" => "subtitle", "value" => "", "description" => __("Subtitle displayed under the main Heading.", 'veented_backend'), "admin_label" => true), array("type" => "textfield", "heading" => __("Button 1 Label", 'veented_backend'), "param_name" => "button1_title", "description" => __("Enter the title for the first button", 'veented_backend'), "value" => "Click me!", "admin_label" => true), array("type" => "textfield", "heading" => __("Button 1 Sublabel (optional)", 'veented_backend'), "param_name" => "button1_subtitle", "description" => __("Optional button secondary label (available for Centered style).", 'veented_backend'), "value" => ""), array("type" => "textfield", "heading" => __("Button 1 Link", 'veented_backend'), "param_name" => "button1_url", "description" => __("Enter the URL the first button will link to", 'veented_backend'), "value" => "http://"), array("type" => "textfield", "heading" => __("Button 2 Label", 'veented_backend'), "param_name" => "button2_title", "description" => __("Enter the title for the second button", 'veented_backend'), "value" => "Click me!", "admin_label" => true), array("type" => "textfield", "heading" => __("Button 2 Sublabel (optional)", 'veented_backend'), "param_name" => "button2_subtitle", "description" => __("Optional button secondary label (available for Centered style).", 'veented_backend'), "value" => ""), array("type" => "textfield", "heading" => __("Button 2 Link", 'veented_backend'), "param_name" => "button2_url", "description" => __("Enter the URL the second button will link to", 'veented_backend'), "value" => "http://"), array("type" => "dropdown", "class" => "hidden-label", "value" => array("Default (Floated)" => 'default', "Centered" => 'centered'), "heading" => __("Style", "vntd_backend"), "description" => __('Style of your Call to Action area.', "veented_backed"), "param_name" => "style"), array("type" => "colorpicker", "heading" => __("Text color", "veented_backed"), "param_name" => "text_color", "value" => '', "description" => __("Select text color. Leave blank for default", "js_composer")), array("type" => "dropdown", "class" => "hidden-label", "value" => array("Dark" => 'dark', "White" => 'white'), "heading" => __("Button Color", "vntd_backend"), "description" => __('Color of your Call to Action area buttons.', "veented_backed"), "param_name" => "button_color"), array("type" => "textfield", "heading" => __("Margin bottom", 'veented_backend'), "param_name" => "margin_bottom", "value" => "0", "dependency" => array('element' => "fullscreen", 'value' => array("yes"))))));
    // Centered Heading
    wpb_map(array("name" => __("Pricing Box", "vntd_backend"), "base" => "pricing_box", "class" => "font-awesome", "icon" => "fa-usd", "category" => 'Content', "description" => "Product box with prices", "params" => array(array("type" => "textfield", "heading" => __("Box Title", 'veented_backend'), "param_name" => "title", "description" => __("Your Pricing Box title", 'veented_backend'), "value" => "", "admin_label" => true), array("type" => "textfield", "heading" => __("Price", 'veented_backend'), "param_name" => "price", "description" => __("Pricing Box price", 'veented_backend'), "value" => "\$99", "admin_label" => true), array("type" => "textfield", "heading" => __("Period", 'veented_backend'), "param_name" => "period", "description" => __("Pricing Box period", 'veented_backend'), "value" => "per year"), array("type" => "exploded_textarea", "heading" => __("Features", "js_composer"), "param_name" => "features", "description" => __('Enter features here. Divide each feature with linebreaks (Enter).', 'js_composer')), array("type" => "dropdown", "class" => "hidden-label", "value" => array("Not Featured" => 'no', "Featured" => 'yes'), "heading" => __("Featured?", "vntd_backend"), "description" => __('Make the box stand out from the crew.', "veented_backed"), "param_name" => "featured"), array("type" => "textfield", "heading" => __("Button Label", 'veented_backend'), "param_name" => "button_label", "description" => __("Text visible on the box button", 'veented_backend'), "value" => "Buy Now"), array("type" => "textfield", "heading" => __("Button URL", 'veented_backend'), "param_name" => "button_url", "description" => __("Button URL, start with http://", 'veented_backend'), "value" => "", 'dependency' => array('element' => "button_label", 'not_empty' => true)), array("type" => "dropdown", "heading" => __("Animated", "js_composer"), "param_name" => "animated", "value" => array("Yes" => "yes", "No" => "no"), "description" => "Enable the element fade in animation on scroll"), array("type" => "textfield", "heading" => __("Animation Delay", "js_composer"), "param_name" => "animation_delay", "value" => '100', "description" => "Fade in animation delay. Can be used to create a nice delay effect if multiple elements of same type.", "dependency" => array('element' => "animated", 'value' => 'yes')))));
    // Centered Heading
    wpb_map(array("name" => __("Counter", "vntd_backend"), "base" => "counter", "class" => "font-awesome", "icon" => "fa-clock-o", "category" => 'Content', "description" => "Countdown numbers", "params" => array(array("type" => "textfield", "heading" => __("Counter Title", 'veented_backend'), "param_name" => "title", "description" => __("Your Counter title.", 'veented_backend'), "value" => "Days", "admin_label" => true), array("type" => "textfield", "heading" => __("Number value", 'veented_backend'), "param_name" => "number", "description" => __("Value of the counter number.", 'veented_backend'), "value" => "100", "admin_label" => true))));
    // Fullscreen slider
    wpb_map(array("name" => __("Fullscreen Text Slider", "vntd_backend"), "base" => "vntd_fullscreen_slider", "class" => "font-awesome", "icon" => "fa-arrows-alt", "category" => 'Media', "params" => array(array('type' => 'attach_images', 'heading' => __('Background Images', 'js_composer'), 'param_name' => 'images', 'value' => '', 'description' => __('Select images from media library. Leave blank to use row\'s background image/video.', 'js_composer')), array("type" => "textarea", "heading" => __("Static Text", 'veented_backend'), "param_name" => "text_static", "description" => __("Static text displayed on the slider.", 'veented_backend'), "value" => "Hello there", "admin_label" => true), array('type' => 'exploded_textarea', 'heading' => __('Dynamic Text Lines', 'js_composer'), 'param_name' => 'text_dynamic', "value" => 'Welcome to North,We are Designers,We love to Design', 'description' => __('Dynamic Text Lines are displayed one after another as slides. Separate each line with linebreaks (Enter)', 'js_composer')), array('type' => 'dropdown', 'heading' => __('Slider Style', 'js_composer'), 'param_name' => 'style', 'value' => array(__('Style 1', 'js_composer') => 'style1', __('Style 2 (with services slider)', 'js_composer') => 'style2'), 'description' => __('Choose a style for the slider.', 'js_composer')), array("type" => "textfield", "heading" => __("Services post number.", 'veented_backend'), "param_name" => "posts_nr", "description" => __("Number of services type of posts to be displayed in the slider.", 'veented_backend'), "value" => "6", 'dependency' => array('element' => "style", 'value' => 'style2')), array('type' => 'dropdown', 'heading' => __('Background Overlay', 'js_composer'), 'param_name' => 'bg_overlay', 'value' => array('Dark 1' => 'dark1', 'Dark 2' => 'dark2', 'Dark pattern' => 'dots', 'White pattern' => 'dots_white', 'None' => 'none'), 'description' => __('Choose the slider overlay background type.', 'js_composer')), array("type" => "textfield", "heading" => __("Button 1 Label", 'veented_backend'), "param_name" => "button1_label", "description" => __("First button label.", 'veented_backend'), "value" => ""), array("type" => "textfield", "heading" => __("Button 1 URL", 'veented_backend'), "param_name" => "button1_url", "description" => __("First button URL.", 'veented_backend'), "value" => "", 'dependency' => array('element' => "button1_label", 'not_empty' => true)), array("type" => "textfield", "heading" => __("Button 2 Label", 'veented_backend'), "param_name" => "button2_label", "description" => __("Second button label.", 'veented_backend'), "value" => ""), array("type" => "textfield", "heading" => __("Button 2 URL", 'veented_backend'), "param_name" => "button2_url", "description" => __("Second button URL.", 'veented_backend'), "value" => "", 'dependency' => array('element' => "button2_label", 'not_empty' => true)), array("type" => "dropdown", "heading" => __("Animated", "js_composer"), "param_name" => "animated", "value" => array("No" => "no", "Yes" => "yes"), "description" => "Enable the element fade in animation on scroll"), array("type" => "dropdown", "heading" => __("Buttons Color", 'veented_backend'), "param_name" => "buttons_color", "description" => __("Color of your slider buttons.", 'veented_backend'), "value" => array("Dark" => "dark", "Light" => "light")), array("type" => "textfield", "heading" => __("Plus Icon URL", 'veented_backend'), "param_name" => "plus_url", "holder" => "span", "description" => __("URL for the big, PLUS icon. Leave blank to hide the icon.", 'veented_backend'), "value" => ""))));
}