I'm just playing around really...
When i try to check the file type i simply get Array().
[php]
foreach ($_FILES['file']['name'] as $_key => $_value)
{
echo $_value . " was uploaded successfully.<br />";
echo $_FILES['file']['type'] . " <br />";
}
[/php]
So to traverse through the array i added a foreach:
[php]
foreach ($_FILES['file']['name'] as $_key => $_value)
{
echo $_value . " was uploaded successfully.<br />";
foreach($_FILES['file']['type'] as $_x => $_y){
echo $_value . " is in $_y format<br />";
}
}
[/php]
But that gives me this:
Expand|Select|Wrap|Line Numbers
- ut_the_folk_down1.gif was uploaded successfully.
- put_the_folk_down1.gif is in image/gif format
- put_the_folk_down1.gif is in image/jpeg format
- natnme.jpg was uploaded successfully.
- natnme.jpg is in image/gif format
- natnme.jpg is in image/jpeg format
Expand|Select|Wrap|Line Numbers
- ut_the_folk_down1.gif was uploaded successfully.
- put_the_folk_down1.gif is in image/gif format
- natnme.jpg was uploaded successfully.
- natnme.jpg is in image/jpeg format