@import css in nginx

Permalink
I manage to get everything working except @import css still doesn't work. It means the installation page doesn't have any styling.
Js and images works.

My nginx configuration:

user http;
worker_processes 1;

error_log /var/log/nginx/error.log;

events {
worker_connections 4096;
}

http {
#include /etc/nginx/mime.types;
access_log /var/log/nginx/access.log;

sendfile on;
keepalive_timeout 65;
tcp_nodelay on;

gzip on;
gzip_disable "MSIE [1-6]\.(?!.*SV1)";

server {
access_log /var/log/nginx/localhost.access.log;

listen 80;
server_name localhost;
root /srv/http;

## Default location
location / {
index index.php index.html;
}

## Images and static content is treated different
location ~* ^.+.(jpg|jpeg|gif|css|png|js|ico|xml)$ {
access_log off;
expires 30d;
}


location ~ ^(.+\.php)(.*)$ {
fastcgi_split_path_info ^(.+\.php)(.*)$;
fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock;
fastcgi_index index.php;

fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;

fastcgi_param QUERY_STRING $query_string;
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 SCRIPT_FILENAME $document_root$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;

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;
}

## Disable viewing .htaccess & .htpassword
location ~ /\.ht {
deny all;
}

}#end server

} #end http

 
nXqd replied on at Permalink Reply
Just make this work by moving all my c5 from localhost/c5 to localhost.

How can I make this work even in localhost/c5 ?
mkly replied on at Permalink Reply
mkly
Hi, you have a bit more stuff than I have going on when I run nginx, but I'm guessing you should use something like this
location ~ ^(.*)$ {
  alias $document_root/c5/index.php/$1
}


my nginx fu is not that strong yet. I've only switched recently.

Edited.