在网上下了一个图片裁剪的插件jquery.cropzoom.min.js,功能非常的强大,而且还帮我准备了一个php的动态脚本,不费多少功夫就搭好了。而且跑起来挺不错的。裁剪+旋转图片,一键即可。
一开始没什么问题,后来修改时,就出现了一个莫名的错误。详细的描述如下:
××××××××××××××××××××××××××××××××××××××××××××××××××××××××××××
Warning: getimagesize(http://localhost/cms/uploadfiles/2010/08/24/133934.jpg) [function.getimagesize]: failed to open stream: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond. in D:/AppServ/www/cms/test/test.php on line 3
Fatal error: Maximum execution time of 30 seconds exceeded in D:/AppServ/www/cms/test/test.php on line 3
××××××××××××××××××××××××××××××××××××××××××××××××××××××××××××
看到这个错误,我就想是不是getimagesize需要服务器配置什么,因为在家里是行的,我立刻debug了一下:
结果显示挺正常的:
X-Powered-By: PHP/5.2.10 ZendServer
Set-Cookie: ZendDebuggerCookie=127.0.0.1%3A10137%3A0||084|77742D65|1003; path=/
Content-type: text/html
array(7) {
[0]=>
int(800)
[1]=>
int(533)
[2]=>
int(2)
[3]=>
string(24) "width="800" height="533""
["bits"]=>
int(8)
["channels"]=>
int(3)
["mime"]=>
string(10) "image/jpeg"
}