Pross/theme-check — Issue #3: PHP Error and Warnings
Author: bueltge
Created: 2012-02-06 11:10:34+00:00
State: open

Thanks for the plugin; maybe can you fix the follow solutions; i dont have current an acces to githob other one; hard customer proxy ;)

I have different warnings and errors and i fixed this on my dev machine.
main.php, `function check_main( $theme )`
```
if ( $files ) {
foreach( $files as $key => $filename ) {
if ( substr( $filename, -4 ) == '.php' ) {
$php[$filename] = php_strip_whitespace( $filename );
}
else if ( substr( $filename, -4 ) == '.css' ) {
$css[$filename] = file_get_contents( $filename );
}
else {
if ( ! is_dir($filename) )
$other[$filename] = file_get_contents( $filename );
}
}
```

also a answer for this topic here in WPE: http://stackoverflow.com/questions/7587989/how-to-fix-php-warning-file-get-contents

another problem in checkbase.php
`function get_theme_data_from_contents( $theme_data )`

```
if ( isset( $theme_name[1] ) ) {
$name = $theme = wp_kses( trim( $theme_name[1] ), $themes_allowed_tags );
$theme_uri = esc_url( trim( $theme_uri[1] ) );
$description = wp_kses( trim( $description[1] ), $themes_allowed_tags );
} else {
$name = $theme = $theme_uri = $description = __( 'undefined' );
}
```

Thanks for include this in the next version.