RewriteEngine On
RewriteBase /


RewriteCond %{REQUEST_URI} ^/.*\.php
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)\.php /app.php?controller=$1 [L,QSA]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule .* app.php [L]

