I have installed ZenPHOTO 1.4.5 on my local machine(NGINX) and i enabled mod rewrite option on ZenPHOTO admin.
I try to convert new htaccess rule using
http://winginx.com/htaccess, but it does't work.
Then i tried `try_files $uri $uri/ /index.php?$uri`, it works for album but not images.
Where can i get correct code.
Comments
Basically what you need to get NGINX to do is redirect anything that is not directly accessing a file on the file system to the zenphoto index.php script. http://docs.dotcloud.com/guides/nginx/
Also note that where you place these rules is different for NGINX than for Apache. The converter seemed to produce a reasonable looking rule, so maybe you have not placed in in the correct location. http://docs.dotcloud.com/guides/nginx/
I tried with the following rules, it woks fine for me!
`
location ~ \.(gif|jpg|png) {
try_files $uri @img_proxy;
}
location @img_proxy {
rewrite ^(.*)$ /index.php?$1;
}
location / {
try_files $uri $uri/ /index.php?$uri;
}
`