WordPress Redirecting to wp-admin/install.php

I’ve had this problem. I contacted my hosting provider and they told me it happened because I exceeded maximum queries per hour limit and therefore access to the database was temporarily locked, so WP couldn’t read from it.

How to stop certain warning logging in error.log?

“Technically” it’s just a PHP warning and not an error, and you should not have warnings enabled on production servers. You can disable PHP from logging warnings and it will still log errors to the error log file. You can disable PHP warnings by setting it in a custom php.ini file on the server (all … Read more

Hide php Notices in Dashboard

I don’t know how to move the notices to the bottom or if that’s possible at all. To disable the debug mode in wp-admin write in wp-config.php: define( ‘WP_DEBUG’, FALSE === strpos( $_SERVER[‘REQUEST_URI’], ‘/wp-admin/’ ) ); Untested: You could try to enable warnings in admin with: // happens early in wp-admin/admin.php add_filter( ‘secure_auth_redirect’, ‘wpse_67728_error_warnings’ ); … Read more

Uncaught ReferenceError:switchEditors is not defined

it might me entirely different solution that i am providing but it solved the problem for me. I followed these steps: Open the user that is getting error. (WordPress admin menu > users > your profile) Changed the setting of “Disable the visual editor when writing” and saved the settings Again disabled this feature and … Read more

Notice: Constant WP_POST_REVISIONS already defined

I have the same problem before. I put WP_POST_REVISIONS in the end of wp-config.php file and it didn’t work correctly. You should put your codes before defining ABSPATH and before this line: /* That’s all, stop editing! Happy blogging. */ it must be something like in the following: define( ‘WP_POST_REVISIONS’, 6 ); /* That’s all, … Read more

How to log mysql errors from wordpress core?

You should be using the wpdb class for all your own queries. All core queries also use wpdb. See wpdb Show and Hide SQL Errors <?php $wpdb->show_errors(); ?> <?php $wpdb->hide_errors(); ?> You can also print the error (if any) generated by the most recent query with print_error. <?php $wpdb->print_error(); ?> Also see SAVEQUERIES constant for … Read more

Notice: Use of undefined constant SCRIPT_DEBUG

This is a known bug As far as I’m concerned, you can easily fix it by replacing if ( SCRIPT_DEBUG ) { with if ( defined(‘SCRIPT_DEBUG’) && SCRIPT_DEBUG ) { That should suppress the error for now. When WordPress is updated again, this error may be overwritten, but I believe it will be fixed in … Read more