From da1493b95a2f0b5000a487ae373c9318c58d0b2d Mon Sep 17 00:00:00 2001 From: Cash Costello Date: Sun, 24 Oct 2010 21:08:27 +0000 Subject: partial implementation of flash uploader --- actions/ajax_upload.php | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 actions/ajax_upload.php (limited to 'actions/ajax_upload.php') diff --git a/actions/ajax_upload.php b/actions/ajax_upload.php new file mode 100644 index 000000000..3d44df199 --- /dev/null +++ b/actions/ajax_upload.php @@ -0,0 +1,47 @@ +container_guid = $album_guid; +$image->setMimeType(tp_upload_get_mimetype($name)); +$image->simpletype = "image"; +$image->access_id = $album->access_id; +$image->title = substr($name, 0, strrpos($name, '.')); +$image_guid = $image->save(); + +$image->setOriginalFilename($name); +$image->saveImageFile($temp_file, $file_size); + +$image->extractExifData(); +$image->saveThumbnails($image_lib); + +$album->prependImageList(array($image->guid)); + +echo "1"; +exit; \ No newline at end of file -- cgit v1.2.3