WordPress.org

Support

Support » Plugins and Hacks » [Resolved] [Plugin: AddThis] Adding AddThis buttons to custom content types

[Resolved] [Plugin: AddThis] Adding AddThis buttons to custom content types

  • When I am adding AddThis to my Custom Content Types (specifically Events through the Event Manager plugin) the links, although present in the page when I do Inspect Element, are not displayed.

    When I compared normal Posts with the Custom Content Type pages I noticed that the top <script> and <link> includes for the Javascript and CSS for AddThis are missing.

    Note that I am including the AddThis using the custom options (not Before or After). I.e. using the approach documented here.

    I also followed the instructions here and added the following to my functions.php:

    add_filter('addthis_post_exclude', 'addthis_post_exclude');
    function addthis_post_exclude($display)
    {
    //display always, wherever I want!
      $display = true;
      return $display;
    }

    However to no avail.
    How can I force AddThis to display where I want it on Custom Content Types or pages that I want?

    http://wordpress.org/extend/plugins/addthis/

Viewing 1 replies (of 1 total)
  • The reason was that the_content() was not being called in these special custom content types.

    Its working fine now that I added the_content() and fixed the content types to play well with the the_content() function.

Viewing 1 replies (of 1 total)
  • The topic ‘[Resolved] [Plugin: AddThis] Adding AddThis buttons to custom content types’ is closed to new replies.