API CHANGE Removed deprecated File::loadUploaded(), please use Upload directly instead! (from r100495)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@105580 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Ingo Schommer 2010-05-25 03:58:39 +00:00
parent 56ba78b2a5
commit 1e5944c690

View File

@ -237,23 +237,6 @@ class File extends DataObject {
return SAPPHIRE_DIR . "/images/app_icons/{$ext}_32.gif";
}
/**
* Save an file passed from a form post into this object.
* DEPRECATED Please instanciate an Upload-object instead and pass the file
* via {Upload->loadIntoFile()}.
*
* @param $tmpFile array Indexed array that PHP generated for every file it uploads.
* @return Boolean|string Either success or error-message.
*/
function loadUploaded($tmpFile) {
user_error('File::loadUploaded is deprecated, please use the Upload class directly.', E_USER_NOTICE);
$upload = new Upload();
$upload->loadIntoFile($tmpFile, $this);
return $upload->isError();
}
/**
* Should be called after the file was uploaded
*/