15053971836 注册 / 登录

wdcp增加apache

时间: 阅读:476
wdcp增加apache

最佳回答

清风若雨

清风若雨

2023-01-13 06:25:43

所有软件安装目录/www/wdlinux
站点配置文件
/www/wdlinux/nginx/conf/vhost
/www/wdlinux/apache/conf/vhost
数据库配置文件/www/wdlinux/etc/my.cnf
数据库数据文件目录 /www/wdlinux/mysql/var

最新回答共有2条回答

  • 临沂网站建设
    回复
    2023-01-13 08:08:45

    nginx模式默认是不支持pathinfo模式的,类似index.php/index形式的url会被提示找不到页面。下面的通过正则找出实际文件路径和pathinfo部分的方法,让nginx支持pathinfo。
    假如要让 www.linuxeye.com站点支持pathinfo,具体配置如下:

    server {
    listen  80;
    server_name     www.linuxeye.com;
    access_log  logs/www.linuxeye.com.log combined;
    root /home/wwwroot/www.linuxeye.com;
    error_page  404  /404.html;
    index index.html index.htm index.php ;
    location / {
            index  index.php;
            if (!-e $request_filename) {
            rewrite  ^/(.*)$  /index.php/$1  last;
            break;
            }
    }
    location ~ .php {
    fastcgi_pass 127.0.0.1:9000;
    fastcgi_index index.php;
    include fcgi_pathinfo.conf;
    set $real_script_name $fastcgi_script_name;
        if ($fastcgi_script_name ~ "^(.+?.php)(/.+)$") {
        set $real_script_name $1;
        set $p