Hello,
I’m making an uploader in flash that has 3 input fields with each FileReference, and one upload button to make them work. By now, I can upload the three files, but I want to put them in different folders with the php file. So, I need a way to get the input name in the flash source, and change the ‘Filedata’ (default), for that specific value.
<?php
//DATA:
$filename = $_FILES[‘Filedata’][‘name’];
$filetmpname = $_FILES[‘Filedata’][‘tmp_name’];
$fileType = $_FILES[“Filedata”][“type”];
$fileSizeMB = ($_FILES[“Filedata”][“size”] / 1024 / 1000);
//PLACE FILE:
move_uploaded_file($_FILES[‘Filedata’][‘tmp_name’], “…/images/”.$filename);
?>
I get this code in http://www.developphp.com/ .
The input text field in flash is called: fileDisplay (fileDisplay1, fileDisplay2, fileDisplay3).
And the file reference is called: fileRef (fileRef1, fileRef2, fileRef3).
I tried to change ‘Filedata’ with (fileDisplay or fileRef).
Also tried with <?php $Name = $_POST[‘Name’]; … $_FILES[$Name]?>
and in the AS3: variables.Name = (fileDisplay or fileRef).
Nothing…
Thanks in advance for your help!