Cannot Access Admin Area After Migration
I have a problem after migrating a wordpress site from Plesk and IIS to LAMP server.
I cannot access Admin Panel, I can access /wp-admin/ and when I can login successfully but I get redirected to home page and not to Admin Page.
If I set define(‘WP_DEBUG’, true) at wp-config.php file I get this error:
Notice: Use of undefined constant _COOKIE – assumed ‘_COOKIE’ in public_html/wp-content/themes/Avada/includes/fusion-functions.php on line 390
Sorry, you are not allowed to access this page.
This line has the following code:
if (!current_user_can('read') && !isset(${_COOKIE}['wp_min'])) {
I have manually added .htaccess file during migration and its content is:
#BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
Leave an answer