Forums

[resolved] [Plugin: NextGEN Gallery] REPOST: Unrelated Plugin side-effect: bracketed short-codes appear (3 posts)

  1. Neil Simon
    Member
    Posted 3 years ago #

    When one particular user activates my plugin (PeoplePond http://wordpress.org/extend/plugins/peoplepond/), the NG short-code (a slideshow) no longer resolves. They are displayed as a bracketed directive.

    When the user deactivates my plugin, the short-code resolves properly, and all is ok.

    Has anyone seen this kind of behavior before?

    Not sure if it's NG, or PeoplePond.

    Thanks for any clues.

    Neil

  2. Alex Rabe
    Member
    Posted 3 years ago #

    You didn't return the content in your filter hook :
    add_filter ('the_content', 'peoplepond_the_content');

    See http://codex.wordpress.org/Plugin_API#Filters

    function filter_profanity($content) {
        global $profanities;
        foreach($profanities as $profanity) {
            $content=str_ireplace($profanity,'{censored}',$content);
        }
        return $content;
    }

    So use return $contentToDisplay; instead printf ('%s', $contentToDisplay);

  3. Neil Simon
    Member
    Posted 3 years ago #

    Many thanks Alex! Neil

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags