the_content(); ?> </div> <section class="comments"> <h4><a href="#disqus-target">Add A Comment</a> <a href="<?php the_permalink(); ?> #disqus_thread"></a></h4> <div class="social"> <?php $jsps_networks = array('facebook', 'twitter'); juiz_sps($jsps_networks); $imgUrl = wp_get_attachment_url(get_post_thumbnail_id($post->ID)); $current_url = home_url(add_query_arg(array(), $wp->request)); ?> <div class="juiz_sps_links counters_both juiz_sps_displayed_nowhere"> <ul class="juiz_sps_links_list"> <li class="juiz_sps_item juiz_sps_link_pinterest"> <a href="http://www.pinterest.com/pin/create/button/?url=<?php echo $current_url; ?> &media=<?php echo $imgUrl; ?> &description=<?php echo str_replace(' ', '%20', the_title('', '', false));
function sc_4_jsps($atts) { $atts = shortcode_atts(array('buttons' => 'facebook,twitter,mail,google,stumbleupon,linkedin,pinterest,viadeo,digg,weibo', 'counters' => 0, 'current' => 1, 'url' => NULL), $atts); // buttons become array ("digg,mail", "digg ,mail", "digg, mail", "digg , mail", are right syntaxes) $jsps_networks = preg_split('#[\\s+,\\s+]#', $atts['buttons']); $jsps_counters = intval($atts['counters']); $jsps_current_page = intval($atts['current']); $jsps_url = $atts['url']; if ($jsps_current_page == 1) { wp_enqueue_script('juiz_sps_scripts', JUIZ_SPS_PLUGIN_URL . 'js/' . JUIZ_SPS_SLUG . '.min.js', array('jquery'), false, true); } ob_start(); juiz_sps($jsps_networks, $jsps_counters, $jsps_current_page, 1, $jsps_url); //do an echo $jsps_sc_output = ob_get_contents(); ob_end_clean(); return $jsps_sc_output; }