简体   繁体   中英

site load more time in url rewrite using .htaccess file

Hi I am new to url rewrite help in this process.

Actually I want to rewrite my url from :

http://abcd.com/merchant.php?store=2&area=323&storename=Vendor-2

to

http://abcd.com/Vendor-2

But it's not working. When I click on href target that time it is loading. Below is my .htaccess file

Options +FollowSymLinks -MultiViews
# Turn mod_rewrite on
RewriteEngine On
RewriteBase /

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?$1 [L,QSA]

RewriteCond %{THE_REQUEST} ^[A-Z]{3,}\s(.*)/index\.php [NC]
RewriteRule ^ /%1 [R=301,L]

RewriteRule ^([^/]*)\.html$ /merchant\.php?store=1&area=132&storename=$1 [L]

Above file is my .htaccess file but it's not working.

Can somebody give me a suggestion?

# This should match when storename contains [a-zA-Z0-9_-]
RewriteCond %{QUERY_STRING} storename=([\w-]+)
RewriteRule merchant.php /%1 [R=301,L]

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