Support » Fixing WordPress » is_page multiple pages

  • This works:

    <?php if (!is_page(3)) { ?>

    <?php if ($p > 0) { add_count($p);}?>

    <?php } ?>

    But this doesn’t, what am I doing wrong 🙁

    <?php if (!is_page(3) || (!is_page(14) || (!is_page(5) || (!is_page(10) || (!is_page(8) || (!is_page(55) || (!is_page(18)) { ?>

    <?php if ($p > 0) { add_count($p);}?>

    <?php } ?>

Viewing 1 replies (of 1 total)
  • i think the problem is those “parenthesis”. try this:

    <?php if (!is_page(3)) || (!is_page(14)) || (!is_page(5)) || (!is_page(10)) || (!is_page(8)) || (!is_page(55)) || (!is_page(18)) { ?>

    <?php if ($p > 0) { add_count($p);}?>

    <?php } ?>

Viewing 1 replies (of 1 total)
  • The topic ‘is_page multiple pages’ is closed to new replies.