I tried, but then I forgot is was a localhost so I had to put in localhost then the website, but it works great now!
Thank you for all your patience and your expertise, I wouldn't know where else to go and I am grateful.
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteCond %{QUERY_STRING} ^(.*&)?key=([^&]+)(&.*)?$ [NC]
RewriteRule ^old$ /new/%2? [R=301,L]
1. Do I put that code in my htaccess file right after the url path I already have in there?
2. Also, do I only change the last line in the above code you gave me to fit my path, and leave the rest as you gave it?
RewriteRule ^old$ /new/%2? [R=301,L]
RewriteRule ^merch.php?merchant=$1 /merch/merchant/([^/]+/?$ [R=301,L]
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteCond %{QUERY_STRING} ^(.*&)?merchant=([^&]+)(&.*)?$ [NC]
RewriteRule ^merch\.php$ /merch/merchant/%2? [R=301,L]
3. What do the other lines mean, or do?
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteCond %{QUERY_STRING} ^(.*&)?key=([^&]+)(&.*)?$ [NC]
Options +FollowSymLinks -MultiViews
RewriteEngine On
RewriteRule ^merch/merchant/([^/]+)/?$ merch.php?merchant=$1 [QSA,L]
Options +FollowSymLinks -MultiViews
RewriteEngine On
RewriteRule ^merch/merchant/([^/]+)/?$ merch.php?merchant=$1 [QSA,L]
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteCond %{QUERY_STRING} ^(.*&)?merchant=([^&]+)(&.*)?$ [NC]
RewriteRule ^merch\.php$ /merch/merchant/%2? [R=301,L]
- Code: Select all
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteCond %{QUERY_STRING} ^(.*&)?key=([^&]+)(&.*)?$ [NC]
RewriteRule ^old$ /new/%2? [R=301,L]
There are three things you must change: "old", "key" and "new" from the old URL /old?key=value to /new/value.
Options +FollowSymLinks -MultiViews
RewriteEngine On
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteCond %{QUERY_STRING} ^(.*&)?merchant=([^&]+)(&.*)?$ [NC]
RewriteRule ^merch\.php$ /merch/merchant/%2? [R=301,L]
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteCond %{QUERY_STRING} ^(.*&)?categoryid=([^&]+)(&.*)?$ [NC]
RewriteRule ^category\.php$ /category/categoryid/%2? [R=301,L]
RewriteRule ^merch/merchant/([^/]+)/?$ merch.php?merchant=$1 [QSA,L]
RewriteRule ^category/categoryid/([^/]+)/?$ category.php?categoryid=$1 [QSA,L]
Users browsing this forum: No registered users and 25 guests