WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] using get_pages() to get the page template attribute? (2 posts)

  1. dzeriho
    Member
    Posted 2 years ago #

    hello im wondering how to get the page template attribute..can i do this using get_pages()?

  2. dzeriho
    Member
    Posted 2 years ago #

    ok what i needed is $pages = get_pages( array()), then each page needed the template name in a var..
    ive solved it with
    $type = get_post_meta( $page->ID , '_wp_page_template', true )

Topic Closed

This topic has been closed to new replies.

About this Topic