Upload file and create XML

procajlok

Member
Hello!!
After a long time, I came back with new case :D

I know how I can upload file and catch some info from this (through getID3), but - how i can after submit, generate XML file with data from form? There I want data from getID3 and some other, type by user in form.

Best regards! :cool:
 
I would use a PHP plugin with onsubmit event and use PHP SimpleXML to gen the xml string to write to a file.
https://www.php.net/manual/en/book.simplexml.php
Great! Yesterday I try that, and it seems to work, but I have another question. Maybe You know - how I can use on this XML (PHP plugin form, onAfterProcess) data from calc? I tried propably all the ways and nothing.

On calc element I have:
PHP:
$getID3 = FabrikWorker::getID3Instance();
$path = JPATH_SITE . '{uploadfiles___plik}';
$fileInfo = $getID3->analyze($path);
$FileName =  $fileInfo['filename'];

return $FileName;
 
It seems to empty calc field when php onAfterProcess run.
When i change it to getTopContent, and open saved before record, i have that calc value....
 
We are in need of some funding.
More details.

Thank you.

Members online

No members online now.
Back
Top