WordPress.org

Ready to get started?Download WordPress

Forums

Custom Post Template
If is a post template (2 posts)

  1. jeanprado
    Member
    Posted 1 year ago #

    How I can use the if propriety with Custom Post Templates? Like if is a certainly post template, something happen?

    Thanks

    http://wordpress.org/extend/plugins/custom-post-template/

  2. Alex
    Member
    Posted 1 year ago #

    $template = get_post_meta($post->ID, 'custom_post_template', true);
    if($template == 'single-custom-post.php'){
      echo 'this post template is single-post-post.php';
    }

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags