__( 'An icon in a circle with some text beneath it', 'vantage' ), ) // Args ); } public function widget( $args, $instance ) { echo $args['before_widget']; $instance = wp_parse_args( $instance, array( 'title' => '', 'text' => '', 'icon' => '', 'image' => '', 'icon_position' => 'top', 'icon_size' => 'small', 'icon_background_color' => '', 'more' => '', 'more_url' => '', 'all_linkable' => false, 'box' => false, ) ); $icon_styles = array(); if(!empty($instance['image'])) { $icon_styles[] = 'background-image: url('.esc_url($instance['image']).')'; } if( !empty($instance['icon_background_color']) && preg_match('/^#?+[0-9a-f]{3}(?:[0-9a-f]{3})?$/i', $instance['icon_background_color'])) { $icon_styles[] = 'background-color: '.$instance['icon_background_color']; } $icon = $instance['icon']; if ( ! empty( $icon ) ) { $icon = apply_filters('vantage_fontawesome_icon_name', $icon ); } ?>
>

'', 'text' => '', 'icon' => '', 'image' => '', 'icon_position' => 'top', 'icon_size' => 'small', 'icon_background_color' => '', 'more' => '', 'more_url' => '', 'all_linkable' => false, 'box' => false, ) ); $icons = include ( get_template_directory() . '/fontawesome/icons.php' ); $sections = include (get_template_directory().'/fontawesome/icon-sections.php'); if(!empty($instance['icon'])) { $instance['icon'] = apply_filters('vantage_fontawesome_icon_name', $instance['icon'] ); } ?>

__( 'A lovely big headline.', 'vantage' ), ) // Args ); } public function widget( $args, $instance ) { echo $args['before_widget']; ?>

'', 'sub_headline' => '', ) ); ?>

__( 'Add nice little icons that link out to your social media profiles.', 'vantage' ) ) ); $this->networks = apply_filters('vantage_social_widget_networks', array( 'facebook' => __('Facebook', 'vantage'), 'twitter' => __('Twitter', 'vantage'), 'google-plus' => __('Google Plus', 'vantage'), 'rss' => __('RSS', 'vantage'), )); } public function widget( $args, $instance ) { // outputs the content of the widget echo $args['before_widget']; if(!empty($instance['title'])) { echo $args['before_title'].$instance['title'].$args['after_title']; } foreach($this->networks as $id => $name) { if(!empty($instance[$id])) { ?>>'; ?> 'medium', 'title' => '', 'new_window' => false, ) ); $sizes = apply_filters('vantage_social_widget_sizes', array( 'medium' => __('Medium', 'vantage'), )); ?>



networks as $id => $name) { ?>

/>

Vantage Premium.', 'vantage'), admin_url('themes.php?page=premium_upgrade')) ?>

'. $title . ''; $new_title .= ''; $new_title .= ''; $new_title .= ''; $title = $new_title; } return $title; } add_filter('widget_title', 'vantage_filter_carousel_loop', 10, 3); /** * Handle ajax requests for the carousel. */ function vantage_carousel_ajax_handler(){ if(empty($_GET['query'])) return; $query = $_GET['query']; $query['paged'] = $_GET['paged']; $query['post_status'] = 'publish'; $query = new WP_Query($query); ob_start(); ?> ob_get_clean(), 'count' => $query->post_count, ) ); exit(); } add_action('wp_ajax_vantage_carousel_load', 'vantage_carousel_ajax_handler'); add_action('wp_ajax_nopriv_vantage_carousel_load', 'vantage_carousel_ajax_handler');