简体   繁体   中英

How to htaccess redirect this long URL?

I am trying to get my script working. How to redirect and customize the below URL?

https://example.com/order?send=value1&send2=value2&send3=value3

to

https://example.com/order/value1/value2/value3

this site can help you: http://www.generateit.net/mod-rewrite/

RewriteEngine On
RewriteRule ^([^/]*)/([^/]*)/([^/]*)\.html$ /order?send=$1&send2=$2&send3=$3 [L]

Try this rule:

RewriteEngine On

RewriteRule ^(order)/([^/]+)/([^/]+)/([^/]*)/?$ /$1?send=$2&send2=$3&send3=$4 [L,NC,QSA]

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM