Uploaded with ImageShack.us
hi i just try to running my website on nginx i am really impressed the
speed i have search engine script and working apache well i just made 81
port for nginx for testing purpose i found a .htaccess converter to
nginx after this rewrite my site %90 works except if i type michael
autocomplate works but if i put space after michael I i get error this
is the error i get please see picture
i think one of command in htaccess it couldnt converted to nginx command
my question is how can i fix this problem
apache .htaccess
RewriteEngine on
Options +FollowSymlinks
RewriteBase /
RewriteRule .htaccess - [F]
RewriteRule (.)(style.css)$ $2 [L]
RewriteRule (.)(lightbox.css)$ $2 [L]
RewriteRule (.)(userdata/)(.)$ $2$3 [QSA,L]
RewriteRule (.)(maps/)(.)$ $2$3 [QSA,L]
RewriteRule (.)(test/)(.)$ $2$3 [QSA,L]
RewriteRule ^(.)(index.php)(/?)(.)$ index.php?page=index/$4 [QSA,L]
RewriteRule (.)(install/)(.)$ $2$3 [QSA,L]
RewriteRule (.)(addon/)(.)$ $2$3 [QSA,L]
RewriteRule (.)(cron/)(.)$ $2$3 [QSA,L]
RewriteRule (.)(js/)(.)(.js)$ $2$3$4 [L]
RewriteRule (.)(images/)(.)(.)(gif|jpe?g|png|ico)$ $2$3$4$5 [L]
RewriteCond %{request_uri} !^index.php
RewriteRule ^(.*)$ index.php?page=$1 [QSA,L]
automatic converted
return 403;
break;
rewrite /(.)(style.css)$ /$2 last;
rewrite /(.)(lightbox.css)$ /$2 last;
rewrite /(.)(userdata/)(.)$ /$2$3 last;
rewrite /(.)(maps/)(.)$ /$2$3 last;
rewrite /(.)(test/)(.)$ /$2$3 last;
rewrite ^/(.)(index.php)(/?)(.)$ /index.php?page=index/$4 last;
rewrite /(.)(install/)(.)$ /$2$3 last;
rewrite /(.)(addon/)(.)$ /$2$3 last;
rewrite /(.)(cron/)(.)$ /$2$3 last;
rewrite /(.)(js/)(.)(.js)$ /$2$3$4 last;
rewrite /(.)(images/)(.)(.)(gif|jpe?g|png|ico)$ /$2$3$4$5 last;
#ignored: condition 0
rewrite ^/(.*)$ /index.php?page=$1 last;
myconf file is
server {
listen 81;
server_name *.mysite.ws;
access_log /var/log/mysite.access.log main;
error_log /var/log/mysite.error.log;
root /home/mysite/www;
index index.php index.html;
rewrite /(.)(style.css)$ /$2 last;
rewrite /(.)(lightbox.css)$ /$2 last;
rewrite /(.)(userdata/)(.)$ /$2$3 last;
rewrite /(.)(maps/)(.)$ /$2$3 last;
rewrite /(.)(test/)(.)$ /$2$3 last;
rewrite ^/(.)(index.php)(/?)(.)$ /index.php?page=index/$4 last;
rewrite /(.)(install/)(.)$ /$2$3 last;
rewrite /(.)(addon/)(.)$ /$2$3 last;
rewrite /(.)(cron/)(.)$ /$2$3 last;
rewrite /(.)(js/)(.)(.js)$ /$2$3$4 last;
rewrite /(.)(images/)(.)(.)(gif|jpe?g|png|ico)$ /$2$3$4$5 last;
rewrite ^/(.*)$ /index.php?page=$1 last;
location / {
try_files $uri $uri/ /index.php?q=$request_uri;
}
location ~ .php$ {
root html;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME /home/mysite/www$fastcgi_script_name;
include fastcgi_params;
}
}
Posted at Nginx Forum: