Support » Plugins and Hacks » [Resolved] Hide socialite on specific posts
3 years, 10 months ago
I’m placing socialite buttons on the theme itself, placing the following code:
<?php echo $wpsocialite->wpsocialite_markup('small'); ?>
Is there any way to hide that on specific posts ID? I’d like to hide the share buttons on some posts / pages, but the plugins that have this feature are not as good performance-wise as this one 🙂
Be sure to upgrade to the latest version. The new manual markup is <?php wpsocialite_markup(); ?>
<?php wpsocialite_markup(); ?>
Let me think about how to best implement a “hiding” function. For now, you could simply use something like this:
$exclude_ids = array('1','60','62');
This looks at the ID’s you have specified in $exclude_ids, then says “If the current $post->ID is not one of these, then display the wpsocialite_markup function.”
Let me know if that helps.
That works perfectly well Tom, thanks!
3 years, 9 months ago
Does that code go in functions.php? Any particular place? I’m using Genesis and looking to exclude from pages such as http://educulture.com/newsletter-signup-successful/