function sf_social_share($atts = null)
 {
     extract(shortcode_atts(array("center" => ''), $atts));
     if (sf_current_theme() == "atelier") {
         global $post;
         $image = wp_get_attachment_url(get_post_thumbnail_id());
         $page_permalink = urlencode(get_the_permalink());
         $page_title = get_the_title();
         $page_thumb_id = get_post_thumbnail_id();
         $page_thumb_url = wp_get_attachment_url($page_thumb_id);
         $share_output = "";
         if ($center == "yes") {
             $share_output .= '<div class="sf-share-counts center-share-counts">';
         } else {
             $share_output .= '<div class="sf-share-counts">';
             $share_output .= '<h3 class="share-text">' . __("Share", 'swift-framework-plugin') . '</h3>';
             $share_output .= '<a href="https://www.facebook.com/sharer/sharer.php?u=' . $page_permalink . '&height=640&width=660&resizable=0&toolbar=0&menubar=0&status=0&location=0&scrollbars=0" class="sf-share-link sf-share-fb"><i class="fa-facebook"></i><span class="count">0</span></a>';
             $share_output .= '<a href="http://twitter.com/share?text=' . $page_title . '&url=' . $page_permalink . '&height=640&width=660&resizable=0&toolbar=0&menubar=0&status=0&location=0&scrollbars=0" class="sf-share-link sf-share-twit"><i class="fa-twitter"></i><span class="count">0</span></a>';
             $share_output .= '<a href="http://pinterest.com/pin/create/button/?url=' . $page_permalink . '&media=' . $page_thumb_url . '&description=' . $page_title . '&height=640&width=660&resizable=0&toolbar=0&menubar=0&status=0&location=0&scrollbars=0" class="sf-share-link sf-share-pin"><i class="fa-pinterest"></i><span class="count">0</span></a>';
             $share_output .= '</div>';
         }
         return $share_output;
     } else {
         global $post;
         $image = wp_get_attachment_url(get_post_thumbnail_id());
         if ($center == "yes") {
             $share_output = '<div class="article-share share-center" data-buttontext="' . __("Share this", 'swift-framework-plugin') . '" data-image="' . $image . '"></div>';
         } else {
             $share_output = '<div class="article-share" data-buttontext="' . __("Share this", 'swift-framework-plugin') . '" data-image="' . $image . '"></div>';
         }
         return $share_output;
     }
 }
 public function content($atts, $content = null)
 {
     $title = $order = $text_size = $items = $el_class = $width = $el_position = '';
     extract(shortcode_atts(array('title' => '', 'text_size' => '', 'item_count' => '', 'order' => '', 'category' => 'all', 'animation' => 'fade', 'autoplay' => 'yes', 'el_class' => '', 'el_position' => '', 'width' => '1/1'), $atts));
     $output = '';
     // CATEGORY SLUG MODIFICATION
     if ($category == "All") {
         $category = "all";
     }
     if ($category == "all") {
         $category = '';
     }
     $category_slug = str_replace('_', '-', $category);
     // TESTIMONIAL QUERY SETUP
     global $post, $wp_query;
     $paged = get_query_var('paged') ? get_query_var('paged') : 1;
     $testimonials_args = array('orderby' => $order, 'post_type' => 'testimonials', 'post_status' => 'publish', 'paged' => $paged, 'testimonials-category' => $category_slug, 'posts_per_page' => $item_count, 'no_found_rows' => 1);
     $testimonials = new WP_Query($testimonials_args);
     if ($autoplay == "yes") {
         $items .= '<div class="flexslider testimonials-slider content-slider" data-animation="' . $animation . '" data-autoplay="yes"><ul class="slides cS-hidden">';
     } else {
         $items .= '<div class="flexslider testimonials-slider content-slider" data-animation="' . $animation . '" data-autoplay="no"><ul class="slides cS-hidden">';
     }
     // TESTIMONIAL LOOP
     while ($testimonials->have_posts()) {
         $testimonials->the_post();
         $testimonial_text = get_the_content();
         $testimonial_cite = sf_get_post_meta($post->ID, 'sf_testimonial_cite', true);
         $testimonial_cite_subtext = sf_get_post_meta($post->ID, 'sf_testimonial_cite_subtext', true);
         $items .= '<li class="testimonial">';
         $items .= '<div class="slide-content-wrap">';
         if (sf_current_theme() == "uplift") {
             // Testimonial Image setup
             $testimonial_image = rwmb_meta('sf_testimonial_cite_image', 'type=image', $post->ID);
             foreach ($testimonial_image as $detail_image) {
                 $testimonial_image_url = $detail_image['url'];
                 break;
             }
             if (!$testimonial_image) {
                 $testimonial_image = get_post_thumbnail_id();
                 $testimonial_image_url = wp_get_attachment_url($testimonial_image, 'full');
             }
             $testimonial_image = sf_aq_resize($testimonial_image_url, 70, 70, true, false);
             // Testimonial Image
             if ($testimonial_image) {
                 $items .= '<div class="cite-image"><img src="' . $testimonial_image[0] . '" width="' . $testimonial_image[1] . '" height="' . $testimonial_image[2] . '" alt="' . $testimonial_cite . '" /></div>';
             }
             // Testimonial Cite
             if ($testimonial_cite_subtext != "") {
                 $items .= '<cite>' . $testimonial_cite . '<span>' . $testimonial_cite_subtext . '</span></cite>';
             } else {
                 $items .= '<cite>' . $testimonial_cite . '</cite>';
             }
             // Testimonial Text
             $items .= '<div class="testimonial-text text-' . $text_size . '">' . do_shortcode($testimonial_text) . '</div>';
         } else {
             // Testimonial Text
             $items .= '<div class="testimonial-text text-' . $text_size . '">' . do_shortcode($testimonial_text) . '</div>';
             // Testimonial Cite
             if ($testimonial_cite_subtext != "") {
                 $items .= '<cite>' . $testimonial_cite . '<span>' . $testimonial_cite_subtext . '</span></cite>';
             } else {
                 $items .= '<cite>' . $testimonial_cite . '</cite>';
             }
         }
         $items .= '</div>';
         $items .= '</li>';
     }
     wp_reset_postdata();
     $items .= '</ul></div>';
     $quote_icon = apply_filters('sf_quote_icon', '<i class="ss-quote"></i>');
     $el_class = $this->getExtraClass($el_class);
     $width = spb_translateColumnWidthToSpan($width);
     $sidebar_config = sf_get_post_meta(get_the_ID(), 'sf_sidebar_config', true);
     $sidebars = '';
     if ($sidebar_config == "left-sidebar" || $sidebar_config == "right-sidebar") {
         $sidebars = 'one-sidebar';
     } else {
         if ($sidebar_config == "both-sidebars") {
             $sidebars = 'both-sidebars';
         } else {
             $sidebars = 'no-sidebars';
         }
     }
     $el_class .= ' testimonial';
     $output .= "\n\t" . '<div class="spb_testimonial_slider_widget spb_content_element ' . $width . $el_class . '">';
     $output .= "\n\t" . '<div class="spb-bg-color-wrap">';
     $output .= "\n\t\t" . '<div class="spb-asset-content spb_wrapper slider-wrap">';
     $output .= $title != '' ? "\n\t\t\t" . '<div class="heading-wrap"><h3 class="spb-heading spb-center-heading">' . $title . '</h3></div>' : '';
     if ($title == "") {
         $output .= "\n\t\t\t" . '<div class="testimonial-icon">' . $quote_icon . '</div>';
     }
     $output .= "\n\t\t\t" . $items;
     $output .= "\n\t\t" . '</div>';
     $output .= "\n\t\t" . '</div> ' . $this->endBlockComment('.spb_wrapper');
     $output .= "\n\t" . '</div> ' . $this->endBlockComment($width);
     if ($sidebars == "no-sidebars" && $width == "col-sm-12") {
         $output = $this->startRow($el_position, '', true) . $output . $this->endRow($el_position, '', true);
     } else {
         $output = $this->startRow($el_position) . $output . $this->endRow($el_position);
     }
     global $sf_include_carousel;
     $sf_include_carousel = true;
     return $output;
 }