class.upload.phpというライブラリを使って画像のアップロードを実装してみました。今回画像のアップロードで欲しかった機能は下記。 保存する画像名を指定 同名ファイルがあった場合は上書き サムネイル画像も同時に保存 デモページにいろいろな使用例が掲載されています。 サムネイルのリサイズ等はデモページに載ってたので簡単にできたのですが、画像名の指定や上書き設定などは載ってなかったのでソース見ながら設定しました。 <?php require "class.upload.php"; function image_upload($filename){ $image_file = $_FILES['image_file']; $handle = new Upload($_FILES['image_file']); $upload_dir = "/home/user/files/"; if(