Fix the editing of stylesheet files in the theme editor.
git-svn-id: http://svn.automattic.com/wordpress/trunk@12185 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
73666bae79
commit
92ffc891e0
|
@ -38,7 +38,7 @@ if (empty($file)) {
|
||||||
if ( 'theme' == $dir ) {
|
if ( 'theme' == $dir ) {
|
||||||
$file = dirname(dirname($themes[$theme]['Template Dir'])) . $file ;
|
$file = dirname(dirname($themes[$theme]['Template Dir'])) . $file ;
|
||||||
} else if ( 'style' == $dir) {
|
} else if ( 'style' == $dir) {
|
||||||
$file = dirname(dirname($themes[$theme]['Stylesheer Dir'])) . $file ;
|
$file = dirname(dirname($themes[$theme]['Stylesheet Dir'])) . $file ;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -184,7 +184,7 @@ if ($allowed_files) :
|
||||||
$style_show = basename($style_file);
|
$style_show = basename($style_file);
|
||||||
$filedesc = ( $description != $style_file ) ? "$description <span class='nonessential'>($style_show)</span>" : "$description";
|
$filedesc = ( $description != $style_file ) ? "$description <span class='nonessential'>($style_show)</span>" : "$description";
|
||||||
$filedesc = ( $style_file == $file ) ? "<span class='highlight'>$description <span class='nonessential'>($style_show)</span></span>" : $filedesc;
|
$filedesc = ( $style_file == $file ) ? "<span class='highlight'>$description <span class='nonessential'>($style_show)</span></span>" : $filedesc;
|
||||||
$template_mapping[ $description ] = array( _get_template_edit_filename($style_file, $style_file), $filedesc );
|
$template_mapping[ $description ] = array( _get_template_edit_filename($style_file, $stylesheet_dir), $filedesc );
|
||||||
}
|
}
|
||||||
ksort( $template_mapping );
|
ksort( $template_mapping );
|
||||||
while ( list( $template_sorted_key, list( $style_file, $filedesc ) ) = each( $template_mapping ) ) :
|
while ( list( $template_sorted_key, list( $style_file, $filedesc ) ) = each( $template_mapping ) ) :
|
||||||
|
|
Loading…
Reference in New Issue