虛擬機器主機配置如下:
server {
listen 80; server_name demo.com; root /opt/demo/public/; index index.html index.htm index.php; location / { index index.html index.htm index.php; include /usr/local/etc/nginx/conf.d/php-fpm; rewrite ^(.*)/equip(d+).html$ $1/index.php?m=content&c=index&a=lists&catid=$2 last; }
}
路由配置:
Route::get('user/showprofile','UserController@showProfile');
已經搞了三天了,實在不知道是哪裡的問題,請大神指點!
回複內容:
虛擬機器主機配置如下:
server {
listen 80; server_name demo.com; root /opt/demo/public/; index index.html index.htm index.php; location / { index index.html index.htm index.php; include /usr/local/etc/nginx/conf.d/php-fpm; rewrite ^(.*)/equip(d+).html$ $1/index.php?m=content&c=index&a=lists&catid=$2 last; }
}
路由配置:
Route::get('user/showprofile','UserController@showProfile');
已經搞了三天了,實在不知道是哪裡的問題,請大神指點!
在location裡面加上
try_files $uri $uri/ /index.php?$query_string;
試試