<Directory "/var/www/html">
Options -Indexes
AllowOverride All
Require all granted
我改出來的nginx,是用在手機webview上,手機可以看到畫面但是電腦chrome有錯誤出現
連線http://hostname/webview/asset/app/?nm=introstyle會出錯誤
不知是少了哪些重點?
server {
listen 80;
server_name hotstname;
root /var/www/html/webview/;
index index.html index.php index.htm;
location /webview {
alias /var/www/html/webview/;
autoindex off;
allow all;
try_files $uri $uri/ /index.php?$query_string;
}
location ~ .php$ {
root /var/www/html/webview/;
fastcgi_pass 127.0.0.1:9001;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
}
}