开发者

Problem with htaccess (images)

开发者 https://www.devze.com 2023-01-07 15:10 出处:网络
RewriteRule ([a-zA-Z0-9/_]+)/([0-9]+)x([0-9]+)_([0-9a-zA-Z_]+).([0-9a-zA-Z_]+)$ i开发者_运维百科mgsize.php?&w=$2&h=$3img=$1/$4.$5 [L]
RewriteRule ([a-zA-Z0-9/_]+)/([0-9]+)x([0-9]+)_([0-9a-zA-Z_]+).([0-9a-zA-Z_]+)$ i开发者_运维百科mgsize.php?&w=$2&h=$3img=$1/$4.$5 [L]

path to file:

/imgsize.php?w=200&h=100&img=uploads/elvita.jpg

/uploads/100x110_elvita.jpg

why its not working? :(


It looks like you got the answer, but I think the period in the first part of the rule needs to be escaped. So, for instance: .


Just filling in on @Patrick's answer:
RewriteRule ([a-zA-Z0-9/_]+)/([0-9]+)x([0-9]+)_([0-9a-zA-Z_]+)\.([0-9a-zA-Z_]+)$ imgsize.php?&w=$2&h=$3img=$1/$4.$5 [L]

0

精彩评论

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