hello guys how are i have a proplem with upload files
when i tring to uploading images from my script on the server it is not display all images that i uploaded althoug i upload for instance 50 images and when the upload finishe it will just display about 24 images
but on my local host it work's normaly if i upload 50 images it will display 50 images
this problem is just accur on my server
this is my code form uploading images
<?php @session_start();?>
<html>
</head>
<meta charset="utf-8"/>
<link rel="stylesheet" type="text/css" href="admin.css" media="screen"/>
</head>
<body>
<?
?>
<?php
mysql_connect('localhost','root','root')or die (mysql_error());
mysql_select_db('storeimage');
?>
<?php
$allowedExt = array("jpeg","JPEG","jpg","JPG");
if (isset($_FILES['file'])) {
foreach ( $_FILES['file']['tmp_name'] as $key => $file ) {
if ($_FILES["file"]["error"][$key] == UPLOAD_ERR_OK) {
$fileName = $_FILES['file']['name'][$key];
$fileSize = $_FILES['file']['size'][$key];
$fileTemp = $_FILES['file']['tmp_name'][$key];
$fileType = $_FILES["file"]["type"][$key];
$fileExt = pathinfo($fileName, PATHINFO_EXTENSION);
$fileExt = strtolower($fileExt);
$randname=rand().'.jpeg';
if(!in_array($fileExt, $allowedExt))
{
// extention not supported ;
echo "Extension Not Allowed";
continue;
}
else {
move_uploaded_file($fileTemp,'images/'.$randname);
$insert=mysql_query("insert into imagelocation values('','images/$randname')")or die (mysql_error());
$id=mysql_insert_id();
$select=mysql_query("select * from imagelocation where id='$id' ");
while ($row=mysql_fetch_object($select)){
echo "<center><img src='$row->images'/></center><br/><br/>";
}
}
} else {
// Somethign bad happend
echo "please choose the files";
}
}
}
?>
<form action='' method='post' enctype='multipart/form-data'>
<input type='file' name='file[]' multiple />
<input type='submit' name='submit'/>
</form>
<?php
if ($_SESSION['username']){
echo "<a href='logout.php'><div id='welcome'>logout</div></a>";
}
else{die ("<meta http-equiv='refresh' content='0; url=login.php'/>");}
?>
</body>
</html>