Changeset 36193 for branches/3.7/src/wp-includes/class-wp-theme.php
- Timestamp:
- 01/06/2016 05:29:16 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3.7/src/wp-includes/class-wp-theme.php
r25666 r36193 207 207 $this->headers['Name'] = $this->stylesheet; 208 208 if ( ! file_exists( $this->theme_root . '/' . $this->stylesheet ) ) 209 $this->errors = new WP_Error( 'theme_not_found', sprintf( __( 'The theme directory "%s" does not exist.' ), $this->stylesheet) );209 $this->errors = new WP_Error( 'theme_not_found', sprintf( __( 'The theme directory "%s" does not exist.' ), esc_html( $this->stylesheet ) ) ); 210 210 else 211 211 $this->errors = new WP_Error( 'theme_no_stylesheet', __( 'Stylesheet is missing.' ) ); … … 254 254 } else { 255 255 // Parent theme is missing. 256 $this->errors = new WP_Error( 'theme_no_parent', sprintf( __( 'The parent theme is missing. Please install the "%s" parent theme.' ), $this->template) );256 $this->errors = new WP_Error( 'theme_no_parent', sprintf( __( 'The parent theme is missing. Please install the "%s" parent theme.' ), esc_html( $this->template ) ) ); 257 257 $this->cache_add( 'theme', array( 'headers' => $this->headers, 'errors' => $this->errors, 'stylesheet' => $this->stylesheet, 'template' => $this->template ) ); 258 258 $this->parent = new WP_Theme( $this->template, $this->theme_root, $this ); … … 266 266 if ( is_a( $_child, 'WP_Theme' ) && $_child->template == $this->stylesheet ) { 267 267 $_child->parent = null; 268 $_child->errors = new WP_Error( 'theme_parent_invalid', sprintf( __( 'The "%s" theme is not a valid parent theme.' ), $_child->template) );268 $_child->errors = new WP_Error( 'theme_parent_invalid', sprintf( __( 'The "%s" theme is not a valid parent theme.' ), esc_html( $_child->template ) ) ); 269 269 $_child->cache_add( 'theme', array( 'headers' => $_child->headers, 'errors' => $_child->errors, 'stylesheet' => $_child->stylesheet, 'template' => $_child->template ) ); 270 270 // The two themes actually reference each other with the Template header. 271 271 if ( $_child->stylesheet == $this->template ) { 272 $this->errors = new WP_Error( 'theme_parent_invalid', sprintf( __( 'The "%s" theme is not a valid parent theme.' ), $this->template) );272 $this->errors = new WP_Error( 'theme_parent_invalid', sprintf( __( 'The "%s" theme is not a valid parent theme.' ), esc_html( $this->template ) ) ); 273 273 $this->cache_add( 'theme', array( 'headers' => $this->headers, 'errors' => $this->errors, 'stylesheet' => $this->stylesheet, 'template' => $this->template ) ); 274 274 }
Note: See TracChangeset
for help on using the changeset viewer.