Thursday 02 November 2006 5:01:15 pm
Hoi Clemens I was looking for something else when I bumped into kernel/classes/ezcontentupload.php function handleUpload( &$result, $httpFileIdentifier, $location, $existingNode ) not exactly what you're looking for either; because it uses upload.ini to determine what object class to use for a mimetype, and then chooses its attribute itself. but it could help / aka the code you need might be in there ?
for example, I see $status = $dataMap[$fileAttribute]->insertHTTPFile( $object, $publishVersion, eZContentObject::defaultLanguage(), $file, $mimeData, $storeResult ); oh, .. ok, .. insertHTTPFile looks like 99% your code :-) except for
$db =& eZDB::instance();
$db->begin();
....code
$db->commit();
eh; dont know.
good luck! *pike
---------------
The class eZContentObjectTreeNode does.
|