AltoRouter Запрещенная ошибка
Я новичок в AltoRouter, я пытаюсь настроить его на своем сервере, так как веб-сайтов много, только для одного из них, я изменил свой apache.conf для
<Directory /var/www/>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
Затем я создал site.com.conf для сайта (важные части):
DocumentRoot /var/www/site.com/public_html
RewriteEngine on
и затем я создаю.htaccess в /var/www/site.com/public_html, например:
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule . /index.php [L]
и index.php:
require 'AltoRouter.php';
$router = new AltoRouter();
$router->setBasePath('/views');
/* Setup the URL routing. This is production ready. */
// Main routes that non-customers see
$router->map('GET','/', '/home.php', 'home');
$router->map('GET','/home/', '/home.php', 'home-home');
$router->map('GET','/about/', '/about.php', 'about');
$match = $router->match();
if($match) {
require $match['target'];
}
else {
header("HTTP/1.0 404 Not Found");
require 'views/404.php';
}
и когда я набираю site.com/about или site.com/home, это дает мне ошибку 403 Спасибо