mirror of
git://develop.git.wordpress.org/
synced 2025-03-14 17:09:47 +01:00
Define TEMPLATEPATH. Look for footer, sidebar, and header in the template directory for the active theme.
git-svn-id: https://develop.svn.wordpress.org/trunk@1922 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
f7d12dbbee
commit
6a2e9a95c1
@ -202,7 +202,7 @@ if ( (0 == count($posts)) && !is_404() && !is_search()
|
||||
$wp_did_header = true;
|
||||
endif;
|
||||
|
||||
$wp_template_dir = get_template_directory();
|
||||
$wp_template_dir = TEMPLATEPATH;
|
||||
|
||||
// Template redirection
|
||||
if ($pagenow == 'index.php') {
|
||||
|
@ -1,8 +1,8 @@
|
||||
<?php
|
||||
// If a footer.php file exists in the WP root directory we
|
||||
// use that, otherwise use this default wp-footer.php file.
|
||||
if ( file_exists(ABSPATH . '/footer.php') ) :
|
||||
include_once(ABSPATH . '/footer.php');
|
||||
if ( file_exists(TEMPLATEPATH . '/footer.php') ) :
|
||||
include_once(TEMPLATEPATH . '/footer.php');
|
||||
else :
|
||||
?>
|
||||
</div>
|
||||
|
@ -1,8 +1,8 @@
|
||||
<?php
|
||||
// If a header.php file exists in the WP root directory we
|
||||
// use that, otherwise use this default wp-header.php file.
|
||||
if ( file_exists(ABSPATH . '/header.php') ) :
|
||||
include_once(ABSPATH . '/header.php');
|
||||
if ( file_exists(TEMPLATEPATH . '/header.php') ) :
|
||||
include_once(TEMPLATEPATH . '/header.php');
|
||||
else :
|
||||
?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
|
@ -96,6 +96,8 @@ if ( get_settings('active_plugins') ) {
|
||||
}
|
||||
}
|
||||
|
||||
define('TEMPLATEPATH', get_template_directory());
|
||||
|
||||
function shutdown_action_hook() {
|
||||
do_action('shutdown', '');
|
||||
}
|
||||
|
@ -1,8 +1,8 @@
|
||||
<?php
|
||||
// If a sidebar.php file exists in the WP root directory we
|
||||
// use that, otherwise use this default wp-sidebar.php file.
|
||||
if ( file_exists(ABSPATH . '/sidebar.php') ) :
|
||||
include_once(ABSPATH . '/sidebar.php');
|
||||
if ( file_exists(TEMPLATEPATH . '/sidebar.php') ) :
|
||||
include_once(TEMPLATEPATH . '/sidebar.php');
|
||||
else :
|
||||
?>
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user