简体   繁体   English

zf2路由的权限问题

[英]Permission issue with zf2 routing

In my main domain I have created a sub domain where I have uploaded my files of ZF2 but it it not allowing me to access the home page. 在我的主域中,我创建了一个子域,在该子域中我上传了ZF2的文件,但是它不允许我访问主页。

If I type <submdomainname>.<domainname>.com it is saying that: 如果输入<submdomainname>.<domainname>.com ,则表示:

Forbidden: 禁止:

You don't have permission to access / on this server. 您无权访问此服务器上的/。

Additionally: 另外:

a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request. 尝试使用ErrorDocument处理请求时遇到404 Not Found错误。

Sounds indeed like a server configuration issue. 听起来确实确实像服务器配置问题。 Try once to put a simle index.php in your folder and see if you can open it: 尝试一次将simle index.php放在您的文件夹中,看看是否可以打开它:

index.php : index.php

<?php
echo("Hello world");

And add it to your public folder and try to browse to it: 并将其添加到您的公用文件夹,然后尝试浏览到它:

http://www.example.com/public/index.php

If that doesn't work, then you know at least that it is not related to ZF2. 如果那不起作用,那么您至少知道它与ZF2没有关系。 After you tried this you can come back with more details on your problem. 尝试此操作后,您可以返回有关问题的更多详细信息。

You should add reading permission to the folder where you host your subdomain. 您应该向托管子域的文件夹添加阅读权限。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM