22
0
Fork 0

Ajout d'une règle RewriteCond pour substituer un caractère dans une url

This commit is contained in:
btatu 2019-11-07 18:06:56 +01:00
parent 7c9b22220e
commit 81c4d8bc62
1 changed files with 4 additions and 0 deletions

View File

@ -780,6 +780,10 @@ Header Set Cache-Control "max-age=0, no-store"
RewriteCond %{REQUEST_URI} ^/index\.php$
RewriteCond %{QUERY_STRING} ^parametre=valeur$
RewriteRule (.*) /page-destination [QSD,R=301,L]
# Substituer un caractère (tel que page.php/ en page.php? ) :
RewriteCond %{REQUEST_URI} (.*page.php)\/(key=.*)
RewriteRule (.*) /%1?%2 [QSD,R=301,L]
~~~
Pour supprimer un Query String avec une Rewrite Rule :