ID ), 'full' ); // Construct sharing URL without using any script $twitterURL = 'https://twitter.com/intent/tweet?text='.$asbTitle.'&url='.$asbURL.'&via=asb'; $facebookURL = 'https://www.facebook.com/sharer/sharer.php?u='.$asbURL; $googleURL = 'https://plus.google.com/share?url='.$asbURL; $bufferURL = 'https://bufferapp.com/add?url='.$asbURL.'&text='.$asbTitle; $whatsappURL = 'whatsapp://send?text='.$asbTitle . ' ' . $asbURL; $linkedInURL = 'https://www.linkedin.com/shareArticle?mini=true&url='.$asbURL.'&title='.$asbTitle; // Based on popular demand added Pinterest too $pinterestURL = 'https://pinterest.com/pin/create/button/?url='.$asbURL.'&media='.$asbThumbnail[0].'&description='.$asbTitle; // Add sharing button at the end of page/page content $content .= ''; $content .= '
'; return $content; }else{ // if not a post/page then don't include sharing button return $content; } }; add_filter( 'the_content', 'asb_social_sharing_buttons'); function asb_add_theme_scripts() { wp_enqueue_style( 'style', get_stylesheet_uri() ); wp_enqueue_style( 'slider', plugin_dir_url( __FILE__ ) . 'assets/style.css', array(), '1.1', 'all'); // wp_enqueue_script( 'script', get_template_directory_uri() . '/js/script.js', array ( 'jquery' ), 1.1, true); // if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) { // wp_enqueue_script( 'comment-reply' ); // } // // tnx Rasool Abdolahi } add_action( 'wp_enqueue_scripts', 'asb_add_theme_scripts' );