Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/.htaccess/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Apache Yii DocumentRoot在共享主机上_Apache_.htaccess_Yii_Document Root - Fatal编程技术网

Apache Yii DocumentRoot在共享主机上

Apache Yii DocumentRoot在共享主机上,apache,.htaccess,yii,document-root,Apache,.htaccess,Yii,Document Root,我的共享主机有一个大问题。我已使用此文件夹结构开发了我的应用程序: /DocumentRoot /backend /www /common /frontend /www 我已要求将域的文档根目录更改为/frontend/www,但他们不支持此更改。是否有任何方法可以配置.htaccess和应用程序在不更改DocumentRoot的情况下使用此文件夹结构 谢谢您您的web主机是否允许您将任何文件放在DocumentRoot之上?嗨,Rowan!我已经和我的提供商谈过了

我的共享主机有一个大问题。我已使用此文件夹结构开发了我的应用程序:

/DocumentRoot
  /backend
    /www
  /common
  /frontend
    /www
我已要求将域的文档根目录更改为/frontend/www,但他们不支持此更改。是否有任何方法可以配置.htaccess和应用程序在不更改DocumentRoot的情况下使用此文件夹结构


谢谢您

您的web主机是否允许您将任何文件放在DocumentRoot之上?嗨,Rowan!我已经和我的提供商谈过了,他们允许我比DocumentRoot高一级。有什么想法吗?谢谢,所以将前端/www移到DocumentRoot,后端/www移到admin,以及将其他所有内容移到受保护的文件夹并不是什么大问题。然后您需要在index.php、admin/index.php中配置路径,并将正确的.htaccess添加到受保护的文件夹中。谢谢Martin!这可能是一个很好的解决方案。