开发者

Using .htaccess to create clean URL structure

开发者 https://www.devze.com 2023-01-05 22:52 出处:网络
How do i redirect website.com/path/?p=4927304 to website.com/path/4927304 whe开发者_开发知识库re the number is dynamic.

How do i redirect

website.com/path/?p=4927304

to

website.com/path/4927304

whe开发者_开发知识库re the number is dynamic.

Many thanks


This rule will redirect URLs like /path/?p=4927304 to /path/4927304:

RewriteCond %{QUERY_STRING} ^p=([0-9]+)$
RewriteRule ^path/$ /path/%1 [R]
0

精彩评论

暂无评论...
验证码 换一张
取 消