Changes between Version 6 and Version 7 of Ticket #13239, comment 103
- Timestamp:
- 10/10/2016 12:20:29 PM (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #13239, comment 103
v6 v7 30 30 <?php 31 31 add_filter( 'template_locations', function( $locations ) { 32 array_walk( $locations, function ( &$v, $s ) { $v .= $s; }, '/partials /' );32 array_walk( $locations, function ( &$v, $s ) { $v .= $s; }, '/partials' ); 33 33 return $locations; 34 34 }, 10, 1 ); … … 42 42 add_filter( 'locate_template', function( $location, $template_names ) { 43 43 if ( in_array( 'header.php', $template_names ) ) { 44 $location = ( is_child_theme() ) ? get_stylesheet_directory() . '/partials': get_template_directory() . '/partials';44 $location = ( is_child_theme() ) ? get_stylesheet_directory() : get_template_directory() . '/partials'; 45 45 } 46 46 return $location;