WP database error: specified key too long and PHP warnings
-
I am running PHP 5.6.25 have just installed the plugin, but before activating had an error and warnings. I uninstalled the plugin, but would still like to try if they can be corrected. For additional information, I ran debug and found many instances of the following error and warnings:
[07-Aug-2017 04:54:57 UTC] WordPress database error Specified key was too long; max key length is 1000 bytes for query CREATE TABLE wp_wpcsplog (id mediumint(9) NOT NULL AUTO_INCREMENT, violated_directive varchar(50) NOT NULL default ”,
blocked_uri varchar(1024) NOT NULL default ”,
document_uri varchar(1024) NOT NULL default ”,
useragent varchar(1024) NOT NULL default ”,
remoteaddress varchar(1024) NOT NULL default ”,
information text NOT NULL default ”,
createdon timestamp DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY id (id),
KEY violated_directive (violated_directive, blocked_uri),
KEY createdon (createdon)
) DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_520_ci made by require_once(‘H:\WAMP64\www\WP-Apsara\wp-admin\admin.php’), require_once(‘H:\WAMP64\www\WP-Apsara\wp-load.php’), require_once(‘H:\WAMP64\www\WP-Apsara\wp-config.php’), require_once(‘H:\WAMP64\www\WP-Apsara\wp-settings.php’), do_action(‘plugins_loaded’), WP_Hook->do_action, WP_Hook->apply_filters, call_user_func_array, wpCSPAdmin::update_database, dbDelta[07-Aug-2017 05:16:38 UTC] PHP Warning: array_key_exists() expects parameter 2 to be array, string given in \wp-content\plugins\http-headers\views\cache-control.php on line 47
PHP Warning: Illegal string offset ‘default’ in \wp-content\plugins\http-headers\views\expires.php on line 74
- The topic ‘WP database error: specified key too long and PHP warnings’ is closed to new replies.