Use of undefined constant NONCE_SALT

Error message

Use of undefined constant NONCE_SALT ... in Shortcode.php on line 192

Cause

Salts are secret keys in WordPress, which provide a layer of security to your site. They are defined in the wp-config.php. If you see the error that the NONCE_SALT is undefined, that means your wp-config.php file does not define this salt.

The NONCE_SALT should have been automatically generated for you when you set up your site. If you check WordPress's sample wp-config.php file you can see all salts starting from line 51.

define( 'NONCE_KEY','put your unique phrase here' );

Solution

1
Generate a new NONCE_SALT at WordPress salt generator
2

Open your wp-config.php file (you can use FTP or your host's file manager) and paste the generated NONCE_SALT code.

Paste it there in a similar placement, as you see in the sample file, before the /* That's all, stop editing! Happy publishing. */ comment.

Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.