Make WordPress Core


Ignore:
Timestamp:
12/02/2010 01:54:56 PM (14 years ago)
Author:
nacin
Message:

add_editor_style should include the parent theme CSS before the child theme CSS for override reasons. props JohnPBloch. fixes #14430.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/post.php

    r16660 r16688  
    15461546        $mce_css = array();
    15471547        $style_uri = get_stylesheet_directory_uri();
    1548         if ( TEMPLATEPATH == STYLESHEETPATH ) {
     1548        if ( ! is_child_theme() ) {
    15491549            foreach ( $editor_styles as $file )
    15501550                $mce_css[] = "$style_uri/$file";
     
    15541554            $template_dir = get_template_directory();
    15551555            foreach ( $editor_styles as $file ) {
     1556                if ( file_exists( "$template_dir/$file" ) )
     1557                    $mce_css[] = "$template_uri/$file";
    15561558                if ( file_exists( "$style_dir/$file" ) )
    15571559                    $mce_css[] = "$style_uri/$file";
    1558                 if ( file_exists( "$template_dir/$file" ) )
    1559                     $mce_css[] = "$template_uri/$file";
    15601560            }
    15611561        }
Note: See TracChangeset for help on using the changeset viewer.