💎一站式轻松地调用各大LLM模型接口,支持GPT4、智谱、星火、月之暗面及文生图 广告
[TOC] > [github](https://github.com/verot/class.upload.php) ## 安装 `composer requrie verot/class.upload.php` ## 文件上传 ``` $handle = new upload($_FILES['image_field']); if ($handle->uploaded) { $handle->file_new_name_body = 'image_resized'; $handle->image_resize = true; $handle->image_x = 100; $handle->image_ratio_y = true; $handle->process('/home/user/files/'); if ($handle->processed) { echo 'image resized'; $handle->clean(); } else { echo 'error : ' . $handle->error; } } ```