我希望将目录中的所有图像作为缩略图复制到单独的目录中,然后我可以在我的网站上查看。现在我正在研究phpthumb,但也下载了wideimage 和zen photo。
谢谢,如果您能找到与此完全相同的副本,近似匹配也可能会有所帮助。
这是仅复制单个文件的脚本:
require_once '../ThumbLib.inc.php';
//include the thumb library
$thumb = PhpThumbFactory::create('test.jpg');
//create a new image from the targeted jpegs
$thumb->adaptiveResize(100, 100);
//resize
$thumb->save('test.png', 'png');
//save as 'test' with the file type png
//echo "<img src='$thumb' class='thumb'>";
$thumb->show();
//print the thumbnail to the screen