WordPress.org

Forums

Shareaholic | share buttons, related posts, social analytics & more
[resolved] Custom Post Types rendering Shareaholic Buttons (3 posts)

  1. Hi.
    I'm Josh, developer of Ultimate Tinymce.

    I have a feature in my plugin which uses a custom post type as a widget builder. The custom post type is registered to WP under a unique name (prefexed with an identifier).

    A client brought to my attention the Shareaholic buttons are appearing in the widget areas, where the custom post type is being used as the widget content. Because of this, the buttons are appearing twice: once in the main content area (as expected); and a second time in the sidebar widget area (undesired).

    I have downloaded and installed your plugin to test. After exploring the admin panel; I notice there is only the option to add share buttons to Posts or Pages.. but nothing about custom post types (such as mine, and many others I'm sure).

    My question:

    Would you consider adding an option to allow/disallow the buttons (and related content) to appear on custom post types?

    Thank you very much!

    EDIT:

    I was just doing a little digging around in your code. I think (please excuse my directness; I know you know your plugin better than I) in the 'utilities.php' file, on line #289, is a function which identifies the webpage as "index, page, post, or category".

    I'm pretty sure this is where the issue is originating.

    Again, thank you.

    http://wordpress.org/plugins/sexybookmarks/

  2. I was able to perform a workaround by providing an option to the user to allow/disallow additional content being added by other plugins adding content using `the_content' filter.

    I basically ran an if/else on the options checkbox: If wanting to apply the additional content, it applies the filters tot he content; and if it is not desired, it simply doesn't apply the filters.

    An easy workaround which provides the best of both worlds!
    Man I love WordPress :)

  3. Andrew Tibbetts
    Member
    Posted 1 year ago #

    This also happens with the Custom Post Widget plugin. Widget areas that contain these custom post types, 'content_block', will get the buttons auto-appended. Looking for a solution.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic