Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /
- /en/
- index.php
- about-us.php
- faq.php
- ...
- /fr/
- index.php
- about-us.php
- faq.php
- ...
- ...
- etc.
- # allows for extension-agnostic urls
- RewriteCond %{REQUEST_FILENAME} !-d
- RewriteCond %{REQUEST_FILENAME}.php -f
- RewriteRule ^(.*)$ $1.php
- RewriteEngine On
- # defaults to the english site
- RewriteRule !^[a-z]{2}/ /en%{REQUEST_URI} [L,R=301]
- # allows for extension-agnostic urls
- RewriteCond %{REQUEST_FILENAME} !-d
- RewriteCond %{REQUEST_FILENAME}.php -f
- RewriteRule ^(.*)$ $1.php
- Not Found
- The requested URL /about-us was not found on this server.
- RewriteRule !^(fr|en)/ /en%{REQUEST_URI} [L,R=301]
- RewriteRule !^[a-z]{2}/ /en%{REQUEST_URI} [L,R=301]
Add Comment
Please, Sign In to add comment