Answers for "wp cron 401"

PHP
0

wp cron 401

# Exclude the WP CRON and other scripts from authentication
# Just put this into your .htaccess file
<FilesMatch "(wp-cron.php|another-script.php)$">
Satisfy Any
Order allow,deny
Allow from all
Deny from none
</FilesMatch>
  
# Just add above code to your .htaccess
# reason of wp cron 401 & 404
"
For what it's worth, I was running into the issue of the same message 
within WP-Cron Events but instead with a 404 (not found) code...it's 
hunting for the file http://yourdomain.com/wp-cron.php. My issue turned 
out to be an improper file permission on my wp-cron.php file 
(644 instead of 666) which caused the wp-cron.php file to give the 404... 
Fixed the permissions and now the warning is gone. This file gives a 200 
code now, and cron jobs finally started to run again.
Maybe the 401 that you are receiving is caused by permissions issues on 
this file as well?
"
Posted by: Guest on June-03-2021

Browse Popular Code Answers by Language