jim wrote:
I only need the ability to change the name of the file that is being
uploaded. How would I go about this? I tried changing the [FileReference
instance].name field but this is read only. On the php side I am not sure if
I can pass through other data with the file data.
I did this with the php file...
<?php
if ($_FILES['Filedata']['name']) {
$uploadDir = $_REQUEST['dir']."/";
$uploadFile = $uploadDir . basename($_REQUEST['fileName']);
$uploaded = move_uploaded_file($_FILES['Filedata']['tmp_name'],
$uploadFile);
echo $uploaded;
}
?>
and the line in the flash like so...
file.upload("../../assets/php/uploadFile.php?fileName=" + theFileName +
"&dir=" + theDir
this way i was controlling the directory the files went into and the
filenames of the uploaded files from the flash rather than the php.
hth,
tom.
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com