WordPress admin panel is not working properly [closed]

Question

I have a WordPress site hosted on ec2 instance with Nginx server. I have also enabled Cloudfront. At first, when the site was operating the only HTTP version everything was working fine and when I migrated my site to the HTTPS version. I can see broken CSS on admin side due to Jquery was not loading properly which I resolved by adding define(‘CONCATENATE_SCRIPTS’, false); in wp-config.php. Now as admin side CSS is working properly I am seeing some weird behaviour on admin side e.g when I try to delete the user and click on the delete button nothing happens page gets refreshed but the user is not deleted, same goes for the post or any other thing also Elementor is resulting into white screen of death. Any help, Thanks

[Nginx Conf file]

server {
listen 80;
root /var/www/html;
server_name somedomain.com;
###Start code section added for withelist headers
#if ($http_x_forwarded_proto != 'https') {
#    rewrite ^ https://$host$request_uri? permanent;
#}
###End code section added for withelist headers
location / {
    index                               index.php index.html;
    try_files                           $uri $uri/ /index.php?$args;
}




# Specify a charset
        charset                         utf-8;
# GZIP
        gzip                            off;

# Add trailing slash to */wp-admin requests.
        rewrite /wp-admin$ $scheme://$host$uri/ permanent;

# Prevents hidden files (beginning with a period) from being served
location ~ /. {
        access_log                      off;
        log_not_found                   off;
        deny                            all;
}

###########
# SEND EXPIRES HEADERS AND TURN OFF 404 LOGGING
###########

        location ~* ^.+.(xml|ogg|ogv|svg|svgz|eot|otf|woff|mp4|ttf|css|rss|atom|js|jpg|jpeg|gif|png|ico|zip|tgz|gz|rar|bz2|doc|xls|exe|ppt|tar|mid|midi|wav|bmp|rtf)$ {
        access_log                      off;
        log_not_found                   off;
        expires                         max;
}

# Pass all .php files onto a php-fpm or php-cgi server
location ~ .php$ {
        try_files                       $uri =404;
        include                         /etc/nginx/fastcgi_params;
        fastcgi_read_timeout            3600s;
        fastcgi_buffer_size             128k;
        fastcgi_buffers                 4 128k;
        fastcgi_param                   SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_pass                    unix:/run/php/php7.2-fpm.sock;
        fastcgi_index                   index.php;
        ###Start code section added for withelist headers
        #if ($http_cloudfront_forwarded_proto = 'https') {
        #    set $fe_https 'on';
        #}
        #fastcgi_param HTTPS $fe_https;
        ###End code section added for withelist headers
}
# ROBOTS

location = /robots.txt {
    allow all;
    log_not_found off;
    access_log off;
}

# RESTRICTIONS
location ~* /(?:uploads|files)/.*.php$ {
 deny all;
}
}
0
zuri_nahk 4 months 0 Answers 28 views 0

Leave an answer