Tag Archives: WordPress

WordPress and Suppressed Errors

One of the errors found by the Error Reporting plugin was an E_WARNING thrown by the constant() function. Upon investigation, it was discovered that the core file had the function call prefixed with the "@" error control operator. The log file also contained a few database function errors. The corresponding lines for those were found [...]

is_a Conclusion

Errors: For the majority of WordPress users, the use of is_a in the core files is of little concern. The E_STRICT errors, in PHP versions >= 5.0 < 5.3 only, can be safely ignored and are not a problem if error reporting does not include them. Performance: For those that have PHP versions >= 5.0 [...]

wp-admin includes template.php

This file causes two is_a E_STRICT errors. function wp_category_checklist( $post_id = 0, $descendants_and_self = 0, $selected_cats = false, $popular_cats = false, $walker = null ) { ….. // if ( empty($walker) || !is_a($walker, 'Walker') ) $class_name = 'Walker'; if ( empty($walker) || ( ( get_class($walker) != $class_name ) && !is_subclass_of($walker, $class_name) ) ) ….. function [...]

wp-includes Text Diff Renderer.php

One is_a class Text_Diff_Renderer { ….. function render($diff) ….. // if (is_a($edit, 'Text_Diff_Op_copy')) { $class_name = 'Text_Diff_Op_copy'; if ( ( get_class($edit) == $class_name ) || is_subclass_of($edit, $class_name) ) { Technorati Tags: Errors, WordPress

wp-includes Text Diff.php

The Text_Diff class has a not is_a and an is_a class Text_Diff { ….. function isEmpty() ….. // if (!is_a($edit, 'Text_Diff_Op_copy')) { $class_name = 'Text_Diff_Op_copy'; if ( ( get_class($edit) != $class_name ) && !is_subclass_of($edit, $class_name) ) { ….. function lcs() ….. // if (is_a($edit, 'Text_Diff_Op_copy')) { $class_name = 'Text_Diff_Op_copy'; if ( ( get_class($edit) == $class_name [...]