April 17th, 2019 at 23:19 #76891
I am trying to create a child theme for Roseta using Child Theme Configurator. I got this message:
Notice: Constant WP_CRON_LOCK_TIMEOUT already defined in /home/username/public_html/wp-config.php on line 91 Notice: Constant AUTOSAVE_INTERVAL already defined in /home/username/public_html/wp-config.php on line 92 Notice: Constant WP_POST_REVISIONS already defined in /home/username/public_html/wp-config.php on line 93 Notice: Constant EMPTY_TRASH_DAYS already defined in /home/username/public_html/wp-config.php on line 94
At some point, someone put this in the “auto-install” version of WordPress used by your hosting provider. They supposedly help “optimize” wordpress, but do just the opposite when they are implemented incorrectly.
Unless you are running in debug mode, these notices will not affect the front-end, but will continue to be logged until resolved.
To correct this issue, you will need to manually edit wp-config.php (you have to use FTP or your hosting account file manager) and either:
comment out or delete the constant definitions.
move the definition statements so they appear BEFORE the final require statement as shown below:
// >>>> SHOULD GO HERE!!! <<<< /* That's all, stop editing! Happy blogging. */ /** Absolute path to the WordPress directory. */ if ( !defined('ABSPATH') ) define('ABSPATH', dirname(__FILE__) . '/'); /** Sets up WordPress vars and included files. */ require_once(ABSPATH . 'wp-settings.php’); // >>>> NOT HERE!!! <<<<
If commenting out:
Locate the lines that begin with “define” that correspond to the error notice, and type “//“ before it, e.g.,
// define( ‘WP_CRON_LOCK_TIMEOUT', 60 );April 26th, 2019 at 16:01 #77218
ZedCryout Creations Team
The notices clearly state that you have some WordPress constants defined twice (in wp-config.php and in some other file loaded before it or both occurences in the wp-config.php file).
Either you or someone else with the necessary access did this manually or a plugin was used that writes such constants to the configuration file.
You need to log in to reply to this topic.