Nginx-ru mailing list archive (nginx-ru@sysoev.ru)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: как настроить простой rew rite
изменил nginx.conf так:
worker_processes 1;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;
sendfile on;
keepalive_timeout 65;
server {
listen 80;
server_name flashportal.com;
charset utf-8;
root c:/dev/www/flashportal;
rewrite (.*) /index.php?$1 last;
location / {
try_files $uri $uri/ @codeigniter;
}
location @codeigniter {
fastcgi_pass 127.0.0.1:9123;
fastcgi_param SCRIPT_FILENAME $document_root/index.php;
fastcgi_param QUERY_STRING $uri;
include fastcgi_params1;
}
}
}
fastcgi_params1, строку с QUERY удалил
fastcgi_param REQUEST_METHOD $request_method;
fastcgi_param CONTENT_TYPE $content_type;
fastcgi_param CONTENT_LENGTH $content_length;
fastcgi_param SCRIPT_NAME $fastcgi_script_name;
fastcgi_param REQUEST_URI $request_uri;
fastcgi_param DOCUMENT_URI $document_uri;
fastcgi_param DOCUMENT_ROOT $document_root;
fastcgi_param SERVER_PROTOCOL $server_protocol;
fastcgi_param GATEWAY_INTERFACE CGI/1.1;
fastcgi_param SERVER_SOFTWARE nginx/$nginx_version;
fastcgi_param REMOTE_ADDR $remote_addr;
fastcgi_param REMOTE_PORT $remote_port;
fastcgi_param SERVER_ADDR $server_addr;
fastcgi_param SERVER_PORT $server_port;
fastcgi_param SERVER_NAME $server_name;
# PHP only, required if PHP was built with --enable-force-cgi-redirect
fastcgi_param REDIRECT_STATUS 200;
перезапустил nginx, в логах ошибок нет:
2010/02/09 17:15:31 1484#924: signal process started
Но работает все точно также. Я nginx.conf неправильно изменил? Может я что-то
банальное спрашиваю, но мало что понимаю, так как новичек в этом деле
Posted at Nginx Forum: http://forum.nginx.org/read.php?21,52637,52653#msg-52653
_______________________________________________
nginx-ru mailing list
nginx-ru@xxxxxxxxx
http://nginx.org/mailman/listinfo/nginx-ru
|