| 1 | Index: wp-includes/theme.php |
|---|
| 2 | =================================================================== |
|---|
| 3 | --- wp-includes/theme.php (revision 16497) |
|---|
| 4 | +++ wp-includes/theme.php (working copy) |
|---|
| 5 | @@ -912,8 +912,12 @@ |
|---|
| 6 | * @return string |
|---|
| 7 | */ |
|---|
| 8 | function get_home_template() { |
|---|
| 9 | + $template = get_post_meta( get_queried_object_id(), '_wp_page_template', true); |
|---|
| 10 | $templates = array( 'home.php', 'index.php' ); |
|---|
| 11 | |
|---|
| 12 | + if ( ! empty( $template ) ) |
|---|
| 13 | + array_unshift( $templates, $template ); |
|---|
| 14 | + |
|---|
| 15 | return get_query_template( 'home', $templates ); |
|---|
| 16 | } |
|---|
| 17 | |
|---|