//httpd error log里的报错信息:
Request exceeded the limit of 10 internal redirects due to probable configuration error. Use 'LimitInternalRecursion' to increase
the limit if necessary. Use 'LogLevel debug' to get a backtrace., referer: http://127.0.0.1/MyProject/login/userLogin
网上大部分的答案都是说的是.htaccess的问题,然而我觉得本地的htaccess没有什么问题:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php?_url=/$1 [QSA,L]
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteRule ^$ apg/public/ [L]
RewriteRule (.*) apg/public/$1 [L]
</IfModule>
url是正确的
http://127.0.0.1/MyProject/login/userLogin
但是网页显示的内容不对。
我再看看框架哪里需要改动。我还是觉得框架没有改动成功。
解决方案:
后来查看自己的collection.php里面其中有一个数组,加上了我的project的名字MyProject:
static private $ProjectsArray = array(
'project1',
'project2',
'project3',
'MyProject'
);
该问题解决!再查看我的localhost页面,可以访问我的project登录页面了,框架搭建成功!