class.upload.php is a powerful and mature PHP class to manage uploaded files, and manipulate images in many ways. The script is available under a GPL license.
Hi, the multiple image upload works fine, now I want to save the names to mysql but the query has some problems. I found I can save names through array, this is the output:
This is a PHP issue, not a class issue. Please read the doc!
This array $uploaded is only used to feed the uploaded files to the class. You need to create a new array to store the filenames as you loop through the array $uploaded. For each upload, store $handle->file_dst_name into a new array and then, when you create your query, loop through this array.Reply
Re: multiple images upload save names to mysql (array) new!
Can you help me Colin? I want the sintax code for multiple images upload save names to mysql. I live in Romania, and I`m not speak english very god...can you explaind for me easy? many thanks for youReply
Re: multiple images upload save names to mysql (array) new!
[...]
146 line is:
$sql .= "VALUES ('$id', '".$uploaded[1]['large']."', '".$uploaded[1]['small']."', '".$uploaded[2]['large']."', '".$uploaded[2]['small']."', '".$uploaded[3]['large']."', '".$uploaded[3]['small']."')"; $x = mysql_query($sql);This array $uploaded is only used to feed the uploaded files to the class. You need to create a new array to store the filenames as you loop through the array $uploaded. For each upload, store $handle->file_dst_name into a new array and then, when you create your query, loop through this array.
many thanks for you
However, you can have a look here to get some information and code examples.