Support » Plugins » Add sociable manually to pages

  • rundhc


    Hi there,

    I would like to add sociable to the top of several pages, and I would like to add code manually to these pages. Can someone tell me what code I would use? The Sociable web site suggests at one point that I can use some php code, but when I tried it, the icons didn’t show up. Is there any html code that I can use?

    Thanks for any info.

Viewing 4 replies - 1 through 4 (of 4 total)
  • sociable


    Did you check in the “Changing the location of the icons” section?



    Sorry for the detail, but I probably need to add it: In general, I want the icons to appear at the bottom of my posts. But in a few exceptions I want the icons to appear at the top. Is there a way to manually code pages in those exceptional cases? I tried dropping the php code (referenced in your post) into those pages, and when I published them, the php code appeared on the page, not the icons. So is there a way to drop some kind of code into a page manually?



    You will have to edit the template or add a shortcode ( Maybe we will add it as a new feature in a future release.

    I had a need for a Sociable shortcode for a project I was working on.

    Here is the code I stuck in my theme’s functions.php file that worked for me:

    	// Adds shortcode to load sociable in content
    	function sociable_shortcode() {
    		echo sociable_html();
    		$sociable_shortcode_content = ob_get_clean();
    		return $sociable_shortcode_content;
    	add_shortcode( 'sociable_code', 'sociable_shortcode' );
    		/* To load Sociable, add this line to your page or post:
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Add sociable manually to pages’ is closed to new replies.