[resolved] is_page_template('template_name') won't work in header.php (3 posts)

  1. sepiamystery
    Posted 8 years ago #

    I am using 2.5 beta release and trying to work with custom page templates.

    So I'm trying to use is_page_template('works') in header.php, but it doesn't work. is_page_template() is working fine however.

    I had some trouble getting the template file to show up under Page Template dropdown of admin. But after a few refreshes it worked.

  2. Austin Matzko
    Posted 8 years ago #

    If you're using a template named works.php, then you should check is_page_template('works.php') instead.

  3. sepiamystery
    Posted 8 years ago #

    Wonderful.. it works!

    Thank you so much for the response filosofo.

Topic Closed

This topic has been closed to new replies.

About this Topic