AlloVince/EvaThumber

参数位置不同导致的跳转问题

Closed this issue · 5 comments

重现过程

  1. 进入如下链接正常
    http://www.jiachongs.com:8081/thumb/d/3193,c_1000,g_800,q_90,x_400,y_200.jpg
  2. q_90参数调整到末尾
    http://www.jiachongs.com:8081/thumb/d/3193,c_1000,g_800,x_400,y_200,q_90.jpg
    导致跳转到如下链接,并且端口号消失
    http://www.jiachongs.com/thumb/d/3193,c_1000,g_800,q_30,x_400,y_200.jpg

Nginx配置如下:

server {
listen 8081;
server_name www.jiachongs.com;
root /root/jiachongs/EvaThumber;
location / {
index index.php index.htm index.html;
if (!-e $request_filename){
rewrite ^/(.*)$ /index.php last;
}
}
location ~ .php$ {
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME /root/jiachongs/EvaThumber/$fastcgi_script_name;
include fastcgi_params;
}
}

另外,测试的版本是今天从
https://github.com/AlloVince/EvaThumber
克隆的最新版本

http://avnpc.com/pages/evathumber#toc14
您博客这个位置的连接
http://evathumber.avnpc.com/thumb/d/demo,c_50,g_60,x_40,y_30,w_30.jpg
也有类似的跳转
您的服务器运行在默认的80端口,我的测试环境则是运行在8081端口,

嗨,Allo,我还有一个问题.

Cache-Control:max-age=1209600
Connection:close
Content-Type:image/png
Date:Thu, 09 May 2013 20:49:44 GMT
Expires:Thu, 23 May 2013 20:49:44 GMT
Server:nginx/1.2.4
Transfer-Encoding:chunked
X-Cache:MISS from google.com
X-Cache-Lookup:HIT from google.com:88
X-Powered-By:PHP/5.4.11

按照上述Nginx配置为什么我的图片会产生
X-Powered-By:PHP/5.4.11
这样一个响应头,把后台的php-fpm进程停掉,就产生,502 Bad Gateway,博主你的图片好像没有类似的响应头产生,能够在这里贴出您是怎么配置,万分感谢了.

不好意思一直没顾得上,最近可能会抽时间完善一下EvaThumber。

关于你的问题,可以在php.ini内设置
expose_php = Off
http://blog.wumashi.com/archives/385

fixed by #8