Some 404 errors handled by Nginx, others by Wordpress?


#1

I’ve used EasyEngine to install Wordpress using Nginx and Ubuntu. But I’ve run into an issue regarding 404 errors. Some are handled by Nginx, while others are handled by Wordpress.
For example: http://www.sbbic.org/something.zip shows the Nginx 404 page.

While http://www.sbbic.org/2014/06/17/free-english-khmer-dictionary-mac-osx-download2 shows the template 404 page.

Any idea how to change my nginx configuration so that all 404 errors are handled by Wordpress?
Thanks!


#2

Hi,
Just edit your NGINX site configuration file using following command:
ee site edit site-name.com
and add following rule:

        if (!-e $request_filename) {  
                rewrite ^/(.+)$ /index.php?q=$1 last;  
        }  

#3

Thanks so much - that fixed it! I wonder if that should be added as the default (unless it is and I messed something up)? Thanks again!


#4