Make WordPress Core

Changeset 4131 for trunk/wp-settings.php


Ignore:
Timestamp:
08/30/2006 09:14:37 AM (18 years ago)
Author:
ryan
Message:

Allow stylesheet only themes to provide functions.php. Props skeltoac. fixes #3048

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-settings.php

    r4072 r4131  
    203203validate_current_theme();
    204204define('TEMPLATEPATH', get_template_directory());
     205define('STYLESHEETPATH', get_stylesheet_directory());
    205206
    206207// Load the default text localization domain.
     
    213214
    214215// Load functions for active theme.
    215 if ( file_exists(TEMPLATEPATH . "/functions.php") )
    216     include(TEMPLATEPATH . "/functions.php");
     216if ( TEMPLATEPATH !== STYLESHEETPATH && file_exists(STYLESHEETPATH . '/functions.php') )
     217    include(STYLESHEETPATH . '/functions.php');
     218if ( file_exists(TEMPLATEPATH . '/functions.php') )
     219    include(TEMPLATEPATH . '/functions.php');
    217220
    218221function shutdown_action_hook() {
Note: See TracChangeset for help on using the changeset viewer.