우분투, php5.6, nGinx를 서버에 설치했고 웹 사이트에 몇 개의 프로젝트를 배치했습니다. 나는 디렉토리 아래에 배포해야하는 하나 개의 프로젝트는 CodeIgniter를 개발하고 다음과 같이 내가 Nginx에 구성을 구성했습니다우분투, nGinx 및 codeigniter에서 URL 재 작성을 활성화하는 방법은 무엇입니까?
이location ~* \.(ico|css|js|gif|jpe?g|png)(\?[0-9]+)?$ {
expires max;
log_not_found off;
}
location/{
# Check if a file or directory index file exists, else route it to index.php.
try_files $uri $uri/ /index.php;
}
location ~* \.php$ {
fastcgi_pass unix:/run/php/php5.6-fpm.sock;
include fastcgi.conf;
fastcgi_split_path_info ^(.+\.php)(.*)$;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
location ~ /\.ht {
deny all;
}
URL은 지금 (404) 말을하지 않습니다하지만 이후 내 사이트의 홈 페이지를 보여주고있다 URL 재 작성. 이 문제를 어떻게 해결할 수 있습니까?
소켓을 구성 했습니까? – edlee
귀하의 질문을 이해할 수 있는지 잘 모르겠습니다. 소켓을 올바르게 구성 했습니까? PHP 정보 페이지에 연결할 수 있습니까? 하위 디렉토리 또는 Codeignite 사이트에서 작동하지 않는 것은 무엇입니까? – edlee