[TYPO3-dev] move uploaded file with TCE

stefano cecere scecere at krur.com
Fri May 16 13:03:51 CEST 2008


maybe a simple question, but there is not that much docs or examples around:

i need to move an uploaded file in BE to a subdirectory of the TCA defined one. (i move the uplaoded files in dynamic created directories)


i use a hook to processDatamap_afterDatabaseOperations

and then i use this:

$this->file = array();
$this->file['move'][1]['data'] = $AttachmentPath.$filename;
$this->file['move'][1]['target'] = $newAttachmentPath.$filename';
				
$this->fileProcessor = t3lib_div::makeInstance('t3lib_extFileFunctions');
$this->fileProcessor->init($FILEMOUNTS, $TYPO3_CONF_VARS['BE']['fileExtensions']);
$this->fileProcessor->init_actionPerms($BE_USER->user['fileoper_perms']);
$this->fileProcessor->start($this->file);
$this->fileProcessor->processData();


is it correct?
(i get empty page.. with error in getting the class instantiated)

...

stefano




More information about the TYPO3-dev mailing list