| 1 | ##Reecriture d'url |
|---|
| 2 | Options +FollowSymlinks |
|---|
| 3 | RewriteEngine on |
|---|
| 4 | |
|---|
| 5 | ###### Global |
|---|
| 6 | |
|---|
| 7 | ##Redirection sous domaines |
|---|
| 8 | RewriteCond %{HTTP_HOST} !^www\.codingteam\.net?$ |
|---|
| 9 | RewriteCond %{HTTP_HOST} !^svn\.codingteam\.net?$ |
|---|
| 10 | RewriteCond %{HTTP_HOST} ^([^.]+)\.codingteam\.net?$ |
|---|
| 11 | RewriteRule ^(.*) http://www.codingteam.net/%1-aff.html [R=301,L] |
|---|
| 12 | |
|---|
| 13 | ##Erreurs Apache |
|---|
| 14 | ErrorDocument 400 /erreur.php |
|---|
| 15 | ErrorDocument 401 /erreur.php |
|---|
| 16 | ErrorDocument 403 /erreur.php |
|---|
| 17 | ErrorDocument 404 /erreur.php |
|---|
| 18 | ErrorDocument 500 /erreur.php |
|---|
| 19 | ErrorDocument 503 /erreur.php |
|---|
| 20 | |
|---|
| 21 | ###### Site |
|---|
| 22 | |
|---|
| 23 | ##Chargement de la langue |
|---|
| 24 | RewriteRule ^(.*)_([-a-z]{2,5})\.php$ $1.php?ct_lang=$2 [QSA,L] |
|---|
| 25 | |
|---|
| 26 | ##Classement des logiciels |
|---|
| 27 | RewriteRule ^logiciellibre-([0-9]{1,2})\.html$ /affos.php?id=$1 [L] |
|---|
| 28 | RewriteRule ^logiciellibre-([0-9]{1,2})_([-a-z]{2,5})\.html$ /affos.php?id=$1&ct_lang=$2 [L] |
|---|
| 29 | RewriteRule ^logiciellibre-([0-9]{1,2})-([0-9]+).html$ /affos.php?id=$1&page=$2 [L] |
|---|
| 30 | RewriteRule ^logiciellibre-([0-9]{1,2})-([0-9]+)_([-a-z]{2,5}).html$ /affos.php?id=$1&page=$2&ct_lang=$3 [L] |
|---|
| 31 | |
|---|
| 32 | ##Liste des membres |
|---|
| 33 | RewriteRule ^(.*)-members_([-a-z]{2,5}).html$ /members.php?order=$1&ct_lang=$2 [L] |
|---|
| 34 | RewriteRule ^(.*)-members-([0-9]+)_([-a-z]{2,5}).html$ /members.php?order=$1&page=$2&ct_lang=$3 [L] |
|---|
| 35 | |
|---|
| 36 | ##Serveur Jabber |
|---|
| 37 | RewriteRule ^log-(.*)-jabber.html$ /jabber.php?action=$1 [L] |
|---|
| 38 | RewriteRule ^log-(.*)-jabber_([-a-z]{2,5}).html$ /jabber.php?action=$1&ct_lang=$2 [L] |
|---|
| 39 | RewriteRule ^fortunes-jabber.html$ /jabber.php?fortunes=ok [L] |
|---|
| 40 | RewriteRule ^fortunes-jabber_([-a-z]{2,5}).html$ /jabber.php?fortunes=ok&ct_lang=$1 [L] |
|---|
| 41 | RewriteRule ^fortunes-([0-9]+)-jabber.html$ /jabber.php?fortunes=ok&page=$1 [L] |
|---|
| 42 | RewriteRule ^fortunes-([0-9]+)-jabber_([-a-z]{2,5}).html$ /jabber.php?fortunes=ok&page=$1&ct_lang=$2 [L] |
|---|
| 43 | RewriteRule ^affiche-([0-9]+)-jabber.html$ /jabber.php?show=$1 [L] |
|---|
| 44 | RewriteRule ^affiche-([0-9]+)-jabber_([-a-z]{2,5}).html$ /jabber.php?show=$1&ct_lang=$2 [L] |
|---|
| 45 | |
|---|
| 46 | ##Projets de logiciel libre libre |
|---|
| 47 | RewriteRule ^(.*)-(.*)-delete_([-a-z]{2,5}).html$ /osverif14.php?p=$1&c=$2&ct_lang=$3 [L] |
|---|
| 48 | RewriteRule ^(.*)-aff.html$ /aff.php?p=$1 [L] |
|---|
| 49 | RewriteRule ^(.*)-aff_([-a-z]{2,5}).html$ /aff.php?p=$1&ct_lang=$2 [L] |
|---|
| 50 | RewriteRule ^(.*)-aff-([0-9]+)_([-a-z]{2,5}).html$ /aff.php?p=$1&page=$2&ct_lang=$3 [L] |
|---|
| 51 | RewriteRule ^(.*)-index.html$ /osvoir.php?p=$1 [L] |
|---|
| 52 | RewriteRule ^(.*)-index_([-a-z]{2,5}).html$ /osvoir.php?p=$1&ct_lang=$2 [L] |
|---|
| 53 | RewriteRule ^(.*)-code.html$ /osvoiri.php?p=$1 [L] |
|---|
| 54 | RewriteRule ^(.*)-code_([-a-z]{2,5}).html$ /osvoiri.php?p=$1&ct_lang=$2 [L] |
|---|
| 55 | RewriteRule ^(.*)-actus.html$ /osvoira.php?p=$1 [L] |
|---|
| 56 | RewriteRule ^(.*)-actus_([-a-z]{2,5}).html$ /osvoira.php?p=$1&ct_lang=$2 [L] |
|---|
| 57 | RewriteRule ^(.*)-actus-([0-9]+).html$ /osvoira.php?p=$1&page=$2 [L] |
|---|
| 58 | RewriteRule ^(.*)-actus-([0-9]+)_([-a-z]{2,5}).html$ /osvoira.php?p=$1&page=$2&ct_lang=$3 [L] |
|---|
| 59 | RewriteRule ^(.*)-screen.html$ /osvoirb.php?p=$1 [L] |
|---|
| 60 | RewriteRule ^(.*)-screen_([-a-z]{2,5}).html$ /osvoirb.php?p=$1&ct_lang=$2 [L] |
|---|
| 61 | RewriteRule ^(.*)-down.html$ /osvoirc.php?p=$1 [L] |
|---|
| 62 | RewriteRule ^(.*)-down_([-a-z]{2,5}).html$ /osvoirc.php?p=$1&ct_lang=$2 [L] |
|---|
| 63 | RewriteRule ^(.*)-trad.html$ /osvoird.php?p=$1 [QSA,L] |
|---|
| 64 | RewriteRule ^(.*)-trad_([-a-z]{2,5}).html$ /osvoird.php?p=$1&ct_lang=$2 [QSA,L] |
|---|
| 65 | RewriteRule ^(.*)-trad-lang-([0-9]+).html$ /osvoird.php?p=$1&affiche=lang&id=$2 [QSA,L] |
|---|
| 66 | RewriteRule ^(.*)-trad-lang-([0-9]+)_([-a-z]{2,5}).html$ /osvoird.php?p=$1&affiche=lang&id=$2&ct_lang=$3 [QSA,L] |
|---|
| 67 | RewriteRule ^(.*)-trad-add.html$ /osvoird.php?p=$1&affiche=add [QSA,L] |
|---|
| 68 | RewriteRule ^(.*)-trad-add_([-a-z]{2,5}).html$ /osvoird.php?p=$1&affiche=add&ct_lang=$2 [QSA,L] |
|---|
| 69 | RewriteRule ^(.*)-trad-i.html$ /osvoird.php?p=$1&affiche=i [QSA,L] |
|---|
| 70 | RewriteRule ^(.*)-trad-i_([-a-z]{2,5}).html$ /osvoird.php?p=$1&affiche=i&ct_lang=$2 [QSA,L] |
|---|
| 71 | RewriteRule ^(.*)-trad-e.html$ /osvoird.php?p=$1&affiche=e [QSA,L] |
|---|
| 72 | RewriteRule ^(.*)-trad-e_([-a-z]{2,5}).html$ /osvoird.php?p=$1&affiche=e&ct_lang=$2 [QSA,L] |
|---|
| 73 | RewriteRule ^(.*)-trad-mod.html$ /osvoird.php?p=$1&affiche=mod [QSA,L] |
|---|
| 74 | RewriteRule ^(.*)-trad-mod_([-a-z]{2,5}).html$ /osvoird.php?p=$1&affiche=mod&ct_lang=$2 [QSA,L] |
|---|
| 75 | RewriteRule ^(.*)-com.html$ /osvoire.php?p=$1 [L] |
|---|
| 76 | RewriteRule ^(.*)-com_([-a-z]{2,5}).html$ /osvoire.php?p=$1&ct_lang=$2 [L] |
|---|
| 77 | RewriteRule ^(.*)-com-([0-9]+)_([-a-z]{2,5}).html$ /osvoire.php?p=$1&page=$2&ct_lang=$3 [L] |
|---|
| 78 | RewriteRule ^(.*)-todo.html$ /osvoirf.php?p=$1 [L] |
|---|
| 79 | RewriteRule ^(.*)-todo_([-a-z]{2,5}).html$ /osvoirf.php?p=$1&ct_lang=$2 [L] |
|---|
| 80 | RewriteRule ^(.*)-doc.html$ /osvoirh.php?p=$1 [L] |
|---|
| 81 | RewriteRule ^(.*)-doc_([-a-z]{2,5}).html$ /osvoirh.php?p=$1&ct_lang=$2 [L] |
|---|
| 82 | RewriteRule ^(.*)-doc-(.*)_([-a-z]{2,5})\.html$ /osvoirh.php?p=$1&page=$2&ct_lang=$3 [L] |
|---|
| 83 | RewriteRule ^(.*)-doc-(.*)\.html$ /osvoirh.php?p=$1&page=$2 [L] |
|---|
| 84 | RewriteRule ^(.*)-bugs.html$ /osvoirg.php?p=$1 [QSA,L] |
|---|
| 85 | RewriteRule ^(.*)-bugs_([-a-z]{2,5}).html$ /osvoirg.php?p=$1&ct_lang=$2 [QSA,L] |
|---|
| 86 | RewriteRule ^(.*)-bugs-([a-z]{1}).html$ /osvoirg.php?p=$1&act=$2 [QSA,L] |
|---|
| 87 | RewriteRule ^(.*)-bugs-([a-z]{1})_([-a-z]{2,5}).html$ /osvoirg.php?p=$1&act=$2&ct_lang=$3&page=$4 [QSA,L] |
|---|
| 88 | RewriteRule ^(.*)-bugs-([0-9]+)-([a-z]{1}).html$ /osvoirg.php?p=$1&act=$2 [QSA,L] |
|---|
| 89 | RewriteRule ^(.*)-bugs-([0-9]+)-([a-z]{1})_([-a-z]{2,5}).html$ /osvoirg.php?p=$1&act=$3&ct_lang=$4&page=$2 [QSA,L] |
|---|
| 90 | RewriteRule ^(.*)-bugs-([0-9]+).html$ /osvoirg.php?p=$1&page=$2 [L] |
|---|
| 91 | RewriteRule ^(.*)-bugs-([0-9]+)_([-a-z]{2,5}).html$ /osvoirg.php?p=$1&page=$2&ct_lang=$3 [L] |
|---|
| 92 | RewriteRule ^(.*)-bugs-affiche-([0-9]+).html$ /osvoirg.php?p=$1&id=$2&action=ok [L] |
|---|
| 93 | RewriteRule ^(.*)-bugs-affiche-([0-9]+)_([-a-z]{2,5}).html$ /osvoirg.php?p=$1&id=$2&action=ok&ct_lang=$3 [L] |
|---|
| 94 | |
|---|
| 95 | ##Forum |
|---|
| 96 | RewriteRule ^forumvoir,(.*),([0-9]+),([0-9]+)\.html$ /forumvoir.php?ida=$1&idb=$2&page=$3 [L] |
|---|
| 97 | RewriteRule ^forumvoir,(.*),([0-9]+),([0-9]+)_([-a-z]{2,5})\.html$ /forumvoir.php?ida=$1&idb=$2&page=$3&ct_lang=$4 [L] |
|---|
| 98 | RewriteRule ^forumvoir,(.*),([0-9]+)\.html$ /forumvoir.php?ida=$1&idb=$2 [L] |
|---|
| 99 | RewriteRule ^forumvoir,(.*),([0-9]+)_([-a-z]{2,5})\.html$ /forumvoir.php?ida=$1&idb=$2&ct_lang=$3 [L] |
|---|
| 100 | RewriteRule ^forum,(.*),([0-9]+)\.html$ /forumcat.php?id=$1&page=$2 [L] |
|---|
| 101 | RewriteRule ^forum,(.*),([0-9]+)_([-a-z]{2,5})\.html$ /forumcat.php?id=$1&page=$2&ct_lang=$6 [L] |
|---|
| 102 | RewriteRule ^forum,(.*)_([-a-z]{2,5})\.html$ /forumcat.php?id=$1&ct_lang=$2 [L] |
|---|
| 103 | RewriteRule ^forum,(.*)\.html$ /forumcat.php?id=$1 [L] |
|---|
| 104 | |
|---|
| 105 | ##Forum : Formulaires |
|---|
| 106 | RewriteRule ^forumadd,([a-z]+)\.html$ /forumadd.php?id=$1 |
|---|
| 107 | RewriteRule ^forumadd,([a-z]+)_([-a-z]{2,5})\.html$ /forumadd.php?id=$1&ct_lang=$2 |
|---|
| 108 | RewriteRule ^forumrep,(.*),([0-9]+)\.html$ /forumrep.php?ida=$1&idb=$2 |
|---|
| 109 | RewriteRule ^forumrep,(.*),([0-9]+)_([-a-z]{2,5})\.html$ /forumrep.php?ida=$1&idb=$2&ct_lang=$3 |
|---|
| 110 | RewriteRule ^forumedit,([0-9]+),(.*)_([-a-z]{2,5})\.html$ /forumedit.php?ida=$1&idb=$2&ct_lang=$3 |
|---|
| 111 | RewriteRule ^forumedit,([0-9]+),(.*)\.html$ /forumedit.php?ida=$1&idb=$2 |
|---|
| 112 | RewriteRule ^forumcit,(.*),([0-9]+)\.html$ /forumcit.php?ida=$1&idb=$2&cite=post&codecite=$2 |
|---|
| 113 | RewriteRule ^forumcit,(.*),([0-9]+)_([-a-z]{2,5})\.html$ /forumcit.php?ida=$1&idb=$2&cite=post&codecite=$2&ct_lang=$3 |
|---|
| 114 | RewriteRule ^forumcitrep,(.*),([0-9]+),([0-9]+)\.html$ /forumcit.php?ida=$1&idb=$2&cite=rep&codecite=$3 |
|---|
| 115 | RewriteRule ^forumcitrep,(.*),([0-9]+),([0-9]+)_([-a-z]{2,5})\.html$ /forumcit.php?ida=$1&idb=$2&cite=rep&codecite=$3&ct_lang=$4 |
|---|
| 116 | RewriteRule ^forumeditrep,([0-9]+),([0-9]+),(.*)_([-a-z]{2,5})\.html$ /forumeditrep.php?rep=$1&id=$2&idb=$3&ct_lang=$4 |
|---|
| 117 | RewriteRule ^forumeditrep,([0-9]+),([0-9]+),(.*)\.html$ /forumeditrep.php?rep=$1&id=$2&idb=$3 |
|---|
| 118 | |
|---|
| 119 | ##Membre |
|---|
| 120 | RewriteRule ^profil,(.*)_([-a-z]{2,5})\.html$ /profil.php?ps=$1&ct_lang=$2 [L] |
|---|
| 121 | RewriteRule ^profil,(.*)\.html$ /profil.php?ps=$1 [L] |
|---|
| 122 | RewriteRule ^messagerie,env,([0-9]+)\.html$ /messagerie.php?action=env&page=$1 [L] |
|---|
| 123 | RewriteRule ^messagerie,env,([0-9]+)_([-a-z]{2,5})\.html$ /messagerie.php?action=env&page=$1&ct_lang=$2 [L] |
|---|
| 124 | RewriteRule ^messagerie,([0-9]+)\.html$ /messagerie.php?page=$1 [L] |
|---|
| 125 | RewriteRule ^messagerie,([0-9]+)_([-a-z]{2,5})\.html$ /messagerie.php?page=$1&ct_lang=$2 [L] |
|---|
| 126 | RewriteRule ^messagerie,([a-z]+),([0-9]+)\.html$ /messagerie.php?id=$2&action=$1 [L] |
|---|
| 127 | RewriteRule ^messagerie,([a-z]+),([0-9]+)_([-a-z]{2,5})\.html$ /messagerie.php?id=$2&action=$1&ct_lang=$3 [L] |
|---|
| 128 | RewriteRule ^messagerie,([a-z]+)\.html$ /messagerie.php?action=$1 [L] |
|---|
| 129 | RewriteRule ^messagerie,([a-z]+)_([-a-z]{2,5})\.html$ /messagerie.php?action=$1&ct_lang=$2 [L] |
|---|
| 130 | RewriteRule ^modprofil-([a-z]+)-([0-9]+)_([-a-z]{2,5})\.html$ /modprofil.php?action=$1&id=$2&ct_lang=$3 |
|---|
| 131 | |
|---|
| 132 | ################################## |
|---|
| 133 | |
|---|
| 134 | ##codingbin |
|---|
| 135 | RewriteRule ^paste/([0-9]+)$ /codingbin/public_html/pastebin.php?show=$1 [L] |
|---|
| 136 | RewriteRule ^paste(.*)$ /codingbin/public_html/pastebin.php$1 [L] |
|---|
| 137 | |
|---|
| 138 | |
|---|
| 139 | ##RSS, XML |
|---|
| 140 | RewriteRule ^rss/rss([0-9]+)-projets-([0-9]+)\.xml$ /rss/rss$1-projets.php?id=$2 [L] |
|---|
| 141 | RewriteRule ^rss/rss-(.*)\.xml$ /rss/rss-$1.php [L] |
|---|
| 142 | RewriteRule ^(.*)-index.xml$ /rss/xml.php?p=$1 [L] |
|---|
| 143 | |
|---|
| 144 | ##Divers |
|---|
| 145 | RewriteRule ^faireundon.html$ https://www.paypal.com/cgi-bin/webscr?cmd=_xclick&business=webmaster@codingteam.net&item_name=Faire+un+don&&no_shipping=1&cn=Votre+nom+(facultatif)&tax=0¤cy_code=EUR&lc=FR&bn=PP%2dDonationsBF&charset=UTF%2d8 [L] |
|---|
| 146 | |
|---|
| 147 | ##Compatibilite avec les anciennes versions |
|---|
| 148 | RewriteRule ^member/upload/(.*)$ /upload/$1 [L] |
|---|
| 149 | RewriteRule ^member/mod_profil.php$ /modprofil.php [R=301,L] |
|---|
| 150 | RewriteRule ^forum/images/(.*)$ /images/$1 [L] |
|---|
| 151 | |
|---|
| 152 | ##Réécriture pour les images |
|---|
| 153 | RewriteRule ^(.*)404.jpg$ images/error404.png [L] |
|---|
| 154 | RewriteRule ^(.*)images/avatar/(.*)$ images/face-smile.png [L] |
|---|