Score:0

Can I redirect one specific url in Nginx for WordPress?

in flag

I want to redirect one specific url in Nginx to 'not found' or 'hidden'

url: /wp-admin/load-scripts.php?c=1&load[]=jquery-effects-blind

reason: https://hackerone.com/reports/925425

my codes in nginx.conf are, it's not working :(

server {
    listen 80 default_server;
    server_name _;
    location ~ load-scripts\.php|load-styles\.php {
        deny all;
    }
}
th flag
This nginx configuration is not the nginx configuration for WordPress. So you need to look for the correct configuration in your nginx folder. To find the correct configuration, you can search for the `root` directive in the nginx configs, there should be the path to your WordPress files and if the `root` and your path to the WordPress files are identical, the configuration is the correct configuration.
Michael Hampton avatar
cz flag
Stop running out of date versions of WordPress. There is no need to do this, just update WordPress.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.