Ticket #8446: post-template.php.patch
File post-template.php.patch, 869 bytes (added by , 14 years ago) |
---|
-
post-template.php
430 430 if ( $wpdb->get_var( $wpdb->prepare("SELECT ID FROM $wpdb->posts WHERE post_parent = %d AND post_type = 'page' LIMIT 1", $pageID) ) ) 431 431 $classes[] = 'page-parent'; 432 432 433 if ( $wp_query->post->post_parent ) 433 if ( $wp_query->post->post_parent ) { 434 434 $classes[] = 'page-child'; 435 435 $classes[] = 'parent-pageid-' . $wp_query->post->post_parent; 436 437 if ( is_page_template() ) 436 } 437 if ( is_page_template() ) { 438 438 $classes[] = 'page-template'; 439 439 $classes[] = 'page-template-' . str_replace( '.php', '-php', get_post_meta( $pageID, '_wp_page_template', true ) ); 440 } 440 441 } elseif ( is_search() ) { 441 442 if ( !empty($wp_query->posts) ) 442 443 $classes[] = 'search-results';