Changeset 41376 for trunk/src/wp-admin/theme-editor.php
- Timestamp:
- 09/13/2017 06:07:48 AM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/theme-editor.php
r38722 r41376 64 64 $allowed_files = $style_files = array(); 65 65 $has_templates = false; 66 $default_types = array( 'php', 'css' ); 66 $default_types = array( 67 'bash', 68 'conf', 69 'css', 70 'diff', 71 'htm', 72 'html', 73 'http', 74 'inc', 75 'include', 76 'js', 77 'json', 78 'jsx', 79 'less', 80 'md', 81 'patch', 82 'php', 83 'php3', 84 'php4', 85 'php5', 86 'php7', 87 'phps', 88 'phtml', 89 'sass', 90 'scss', 91 'sh', 92 'sql', 93 'svg', 94 'text', 95 'txt', 96 'xml', 97 'yaml', 98 'yml', 99 ); 67 100 68 101 /** … … 126 159 127 160 default: 161 162 $settings = wp_enqueue_code_editor( compact( 'file' ) ); 163 if ( ! empty( $settings ) ) { 164 wp_enqueue_script( 'wp-theme-plugin-editor' ); 165 wp_add_inline_script( 'wp-theme-plugin-editor', sprintf( 'jQuery( function() { wp.themePluginEditor.init( %s ); } )', wp_json_encode( $settings ) ) ); 166 } 128 167 129 168 require_once( ABSPATH . 'wp-admin/admin-header.php' );
Note: See TracChangeset
for help on using the changeset viewer.