cooldude832 Posted May 16, 2007 Share Posted May 16, 2007 I'm trying to make a image uploader and it works perfect in FF2, but not IE6 This is the snippets involved with it: <form name='ad' action='ad_preview.php' method='post' enctype='multipart/form-data'> <input type='hidden' name='newimages' value='yes'> <input type="file" name="imagefile0"> <br /> <input type="file" name="imagefile1"> <br /> <input type="file" name="imagefile2"> <br /> <input type="file" name="imagefile3"> <br /> Now the Processor Code: $i = 0; $count = 0; //Lets add some nubmers for safety $random_digit = $_POST['random']; $us = "_"; $pathto = "/files/".$random_digit.$us; if ($_POST['newimages'] == "yes") { while ($i <= 3) { if ($_FILES['imagefile'.$i]['type'] == "image/jpeg" || $_FILES['imagefile'.$i]['type'] == "image/jpg") { $count++; $file_name = ""; $file_name .= "temp."; $file_name .= str_replace(".jpg","",str_replace("/","",str_replace("image","",$HTTP_POST_FILES['imagefile'.$i]['type']))); $ext = ".jpg"; //Lets make a new name $new_file_name=$random_digit.$us.$count.$ext; //Lets Path it $path[$count]= "files/".$new_file_name; if(copy($HTTP_POST_FILES['imagefile'.$i]['tmp_name'], $path[$count])) {} } $i++; } } Like i said logically the PHP is perfect in FF2, not IE6,7 Link to comment https://forums.phpfreaks.com/topic/51716-image-uploading-errors-with-ie/ Share on other sites More sharing options...
cooldude832 Posted May 16, 2007 Author Share Posted May 16, 2007 Does IE not use the $_FILE global and the $HTTP_... instead? Link to comment https://forums.phpfreaks.com/topic/51716-image-uploading-errors-with-ie/#findComment-254770 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.