n/oldblog
Archived
1
0
Fork 0
This repository has been archived on 2024-02-13. You can view files and clone it, but cannot push or open issues or pull requests.
oldblog/.htaccess
2023-04-30 21:50:11 +02:00

40 lines
2 KiB
ApacheConf

RewriteEngine On
# Hint by jdMorgan (http://www.webmasterworld.com/forum92/2100.htm)
#
# If requested resource does not exist as a file
#RewriteCond %{REQUEST_FILENAME} !-f
# and does not end with a period followed by a filetype
#RewriteCond %{REQUEST_URI} !\..+$
# and does not end with a slash
#RewriteCond %{REQUEST_URI} !/$
# then add a trailing slash and redirect
#RewriteRule (.*) http://tourmentine.com/$1/ [R=301,L]
# My own rules...
RewriteRule ^ip$ /ip.php [L]
RewriteRule ^news$ http://tourmentine.com/news/ [R=301,L]
RewriteRule ^webnews$ http://tourmentine.com/news/ [R=301,L]
RewriteRule ^dazibaweb$ http://tourmentine.com/news/ [R=301,L]
RewriteRule ^lechat$ http://tourmentine.com/lechat/ [R=301,L]
RewriteRule ^news/$ ?page=news/index [L]
RewriteRule ^webnews/$ ?page=news/index [L]
RewriteRule ^dazibaweb/$ ?page=news/index [L]
RewriteRule ^lechat/$ ?page=lechat/index [L]
RewriteRule ^theme.(.*).html$ /settheme.php?theme=$1
RewriteRule ^billet\.([0-9]+\.([a-z][a-z])\.html)$ /?modulepage=commentnews&idnews=$1&lang=$2 [L]
RewriteRule ^billet\.([0-9]+)\.html$ /?modulepage=commentnews&idnews=$1 [L]
RewriteRule ^comment\.([0-9]+)\.([0-9]+)\.([a-z][a-z])\.html$ /?modulepage=commentnews&idnews=$1&indexmsg=$2&lang=$3 [L]
RewriteRule ^comment\.([0-9]+)\.([0-9]+)\.html$ /?modulepage=commentnews&idnews=$1&indexmsg=$2 [L]
RewriteRule ^scripts/(.*).js$ modules/$1.js.php
#RewriteRule ^([^/]+)/(.*)\.([a-z][a-z])\.html$ ?page=$1/$2&lang=$3 [L]
#RewriteRule ^(.*)\.[a-z][a-z]\.html ?page=$1&lang=$2 [L]
#RewriteRule ^([^/]+)/(.*)\.([fr|en|es])\.html$ ?page=$1/$2&lang=$3 [L]
#RewriteRule ^(.*)\.[fr|en|es]\.html$ ?page=$1&lang=$2 [L]
RewriteRule ^(.*)\.fr\.html$ ?page=$1&lang=fr [L]
RewriteRule ^(.*)\.en\.html$ ?page=$1&lang=en [L]
RewriteRule ^(.*)\.es\.html$ ?page=$1&lang=es [L]
RewriteRule ^(.*)\.html$ ?page=$1 [C,E=WasHTML:yes]