WordPress.org

Support

Support » How-To and Troubleshooting » How to check and show content in page and child pages?

How to check and show content in page and child pages?

  • Hi

    I’m trying to display content in one page and child pages fron these page.

    Today, i’m use this code:

    <?php if (is_page(array('page', 'page-child1', 'page-child2', 'page-child3'))) { //"Childs from "page"
    ##The content if is the pages from array
    } else {
    ##Nothing
    }
    ?>

    I’m newbie in this, but i’m very interesting to learn.

    P. D.: Excuse my english 🙂

  • The topic ‘How to check and show content in page and child pages?’ is closed to new replies.
Skip to toolbar