开发者

htaccess replace two occurs of dot in URL with only one

I'm trying to replace occ开发者_Python百科urs of two dots in my image URL with only one dot

something like this

http://www.test.com/image..jpg

should be

http://www.test.com/image.jpg

I made this one but it seams that not working as I expect.

    RewriteEngine On
    RewriteRule (.*)\..(jpe?g|gif|png)$ $1.$2 [R=302,NC,L]

Any help would be more than welcome.


RewriteRule (.*)\.\.(jpg|gif|bmp|jpeg|png)    $1.$2
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜