Options -Indexes DirectoryIndex index.php RewriteEngine On # Fichiers et répertoires réels servis directement RewriteCond %{REQUEST_FILENAME} -f [OR] RewriteCond %{REQUEST_FILENAME} -d RewriteRule ^ - [L] # URL propre pour les articles : /post/ RewriteRule ^post/([a-z0-9][a-z0-9-]*)/?$ /index.php?action=view&slug=$1 [L,QSA] # Ajoute .php si le fichier correspondant existe RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI}.php -f RewriteRule ^(.+?)/?$ /$1.php [L,QSA]