Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用这个类verot上传类
我想在调整大小后将图像大小调整为最大 50kb。我的想法是使用一段时间循环并在圆圈内进行调整大小,将其保存在磁盘上并使用 php 函数检查新图片的大小。如果它大于 50 公斤,则用较小的调整值再做一个圆圈。
你认为有更好的解决方案吗?感谢帮助
类的创建者在这里。该类已经具有此功能,请参阅jpeg_size参数。例如:
jpeg_size
$handle->jpeg_size = 50000;