wpdb::show_errors
Enables showing of database errors.
This function should be used only to enable showing of errors. wpdb::hide_errors() should be used instead for hiding errors.
Method of the class: wpdb{}
No Hooks.
Returns
true|false. Whether showing of errors was previously active.
Usage
global $wpdb; $wpdb->show_errors( $show );
- $show(true|false)
- Whether to show errors.
Default:true
Notes
- See: wpdb::hide_errors()
Changelog
| Since 0.71 | Introduced. |
wpdb::show_errors() wpdb::show errors code WP 7.0
public function show_errors( $show = true ) {
$errors = $this->show_errors;
$this->show_errors = $show;
return $errors;
}