Quantcast
Channel: Topic Tag: plugin | WordPress.org
Viewing all articles
Browse latest Browse all 26892

datdesignguy on "How To Determine If A Filter Is Called In A Sidebar/Widget Context?"

$
0
0

Have you explored the use of the in_the_loop function? I've never used it, but I could definitely see myself running into this problem someday... So after seeing your problem, I did a few google searches, I came across this function... http://codex.wordpress.org/Function_Reference/in_the_loop

Perhaps something like this would work?

function insert_biography_box ($content) {
    if ( !in_the_loop() ) {
        return $content;
    }

    // do code stuff to append/prepend biography content
    return $content;
}

I hope this helps!

-greg


Viewing all articles
Browse latest Browse all 26892

Trending Articles