Nginx Rewrite to 404

The following Nginx configuration technique will allow you to do rewrites to status codes.

rewrite ^.*?.(?:swf|xml|gif|jpg|png|css|js)$ @404 break; location = @404 { return 404; }

Related posts:

  1. WordPress + Debian Mod Rewrite

Leave a Reply

Your email address will not be published. Required fields are marked *

*