WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] add_filter *not* on the_excerpt (1 post)

  1. Tobias Jordans
    Member
    Posted 8 years ago #

    Hello!

    I am working on a plugin that replaces [sometag] with some code. I want it to apply to every page and single post. But I do *not* want it to apply on the_excerpt (which is autogenerated).

    I tried to apply my function to 'the_content' and wrap it with
    if(!is_single() || !is_page())
    But unfortunatelly those functions return false in any case when they are called inside my plugin: on the excerpt as well as on a page/single-post.

    Does someone have an idea how to solve this?
    Maybe I have to do it manually an wrap all my the_content-calls inside my template?

    Regards

Topic Closed

This topic has been closed to new replies.

About this Topic