WordPress.org

Ready to get started?Download WordPress

Forums

removing action / is_page() not working (1 post)

  1. inspirationally
    Member
    Posted 3 years ago #

    I'm not sure I'm right here - I've got the problem, that removing/adding an action inside the_content is not working.

    Basically, I want to remove the action made by the download monitor plugin
    add_action('init','wp_dlm_init_hooks');
    through the functions.php on all sites BUT the downloads site itself.

    If I add

    if (!is_page('9335')){
    remove_action('init','wp_dlm_init_hooks');
    }

    to my functions.php,
    nothing is working anymore at all - it is removed also from id 9335.

    How can I solve this? This is not plugin specific - it doesn't matter which plugin it is that I want to remove the actions from.

    if (is_page('9335)) { ?>
    BLABLABLA
    <? }

    does display a blablabla anywhere if I add it to my page.php file or to the header.php on that single site. So the is_page IS being recognized, just not, as it seems, INSIDE the the_content() part.

    Can you please help?
    Thank you, Martina.

Topic Closed

This topic has been closed to new replies.

About this Topic

  • RSS feed for this topic
  • Started 3 years ago by inspirationally
  • This topic is not resolved
  • WordPress version: 3.0.4