Drupal issues with try_files

Michael Shadle mike503 at gmail.com
Wed Jun 10 06:50:02 MSD 2009


I'm having an issue here. I was using this shorthand:

try_files $uri $uri/ /index.php?q=$uri&$args;

which would mean /about is /index.php?q=/about

However, in the past, the rewrite is like this (and works great):

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

where it would be /index.php?q=about

Now, the app should handle "/about" just the same as "about"

Is there anything in nginx I could do? A change across the entire
codebase on Drupal and its modules will be complex if there's
something that can be done on the nginx level to pass the URI without
the starting slash...





More information about the nginx mailing list