Blog Tutorial Mod_rewrite error

I'm gettting Modrewrite error when I load the newly created project for the blog tutorial, yet i have modrewrite enabled

How's the error message? Pls mention your OS, PHP Ver, and phalcon version you are using. You have set AllowOverride All, right?



3.7k

When I access http://localhost/blog, I get:

Mod-Rewrite is not enabled

Please enable rewrite module on your web server to continue

OS: Ubuntu 13.04 64-bit PHP Version: 5.4.9 Phalcon Version: 1.1.0

Where should I set AllowOverride All?

  1. Adjust your apache configs in /etc/apache2/sites-available/default like in the http://docs.phalconphp.com/en/latest/reference/apache.html
  2. Enable the mod rewrite: ```bash sudo a2enmod rewrite service apache2 restart ```


3.7k

Thank you so much!!! I'm now flying with Phalcon :)



851

Hi, I'm have the same trouble. I checked this link: http://docs.phalconphp.com/en/latest/reference/apache.html My htaccess files look like this:

\var\www\tutorial.htaccess --- <IfModule mod_rewrite.c> RewriteEngine on RewriteRule ^$ public/ [L] RewriteRule (.*) public/$1 [L] </IfModule>

\var\www\tutorial\public.htaccess --- AddDefaultCharset UTF-8 <IfModule modrewrite.c> RewriteEngine On RewriteCond %{REQUESTFILENAME} !-d RewriteCond %{REQUESTFILENAME} !-f RewriteRule ^(.*)$ index.php?url=/$1 [QSA,L] </IfModule>

My sudo a2enmod rewrite reports: Model rewrite already enabled The web page at url 'http://localhost/tutorial/' is obviously showing the index.html, but the index.php is never loaded

This is Ubuntu 13.10, Apache2, Phalcon, Phalcon-DevTools, php5 Thanks for any help