Je ne suis pas un king des expressions régulière et me contente généralement de faire du copié/collé/modifié pour arriver à mes fins. J'ai déjà utilisé le htaccess pour des redirections 301 mais là rien à faire.
Voici mon htaccess:
CITATION
Options +FollowSymlinks
RewriteEngine on
RewriteRule ^([a-z-]+).html$ /index.php?page=$1 [NC,L]
RewriteRule ^index.php?page=situation$ /situation-locations.html [QSA,L,R=301]
RewriteRule ^index.php?page=environnement$ /environnement-gites.html [QSA,L,R=301]
RewriteRule ^index.php?page=ty_coz$ /location-ty-coz.html [QSA,L,R=301]
RewriteRule ^index.php?page=ty_marchosi$ /location-ty-marchosi.html [QSA,L,R=301]
RewriteRule ^index.php?page=ty_saout_nord$ /location-ty-saout-nord.html [QSA,L,R=301]
RewriteRule ^index.php?page=ty_saout_sud$ /location-ty-zaout-sud.html [QSA,L,R=301]
RewriteEngine on
RewriteRule ^([a-z-]+).html$ /index.php?page=$1 [NC,L]
RewriteRule ^index.php?page=situation$ /situation-locations.html [QSA,L,R=301]
RewriteRule ^index.php?page=environnement$ /environnement-gites.html [QSA,L,R=301]
RewriteRule ^index.php?page=ty_coz$ /location-ty-coz.html [QSA,L,R=301]
RewriteRule ^index.php?page=ty_marchosi$ /location-ty-marchosi.html [QSA,L,R=301]
RewriteRule ^index.php?page=ty_saout_nord$ /location-ty-saout-nord.html [QSA,L,R=301]
RewriteRule ^index.php?page=ty_saout_sud$ /location-ty-zaout-sud.html [QSA,L,R=301]
Vous l'aurez compris, je souhaite rediriger index.php?page=situation vers situation-locations.html mais rien n'y fait ça ne marche pas. Je n'ai pourtant pas oublié le / nécessaire chez OVH. Est-ce que ce ne serait pas du au fait que mon url contient un "?" ou un "=", je ne sais pas.
Une exemple de redirection qui ne fonctionne pas: http://lezoulien.cap-sizun.com/index.php?page=situation
J'espère que vous trouverez une solution à mon problème,
Loïc