関数 get_archive_template()
2014/12/17
関数 get_archive_template()
定義ファイル :/blog/wp-includes/template.php
1 2 3 4 5 6 7 8 9 10 11 12 13 | function get_archive_template() { $post_types = array_filter( (array) get_query_var( 'post_type' ) ); $templates = array(); if ( count( $post_types ) == 1 ) { $post_type = reset( $post_types ); $templates[] = "archive-{$post_type}.php"; } $templates[] = 'archive.php'; return get_query_template( 'archive', $templates ); } |