[B]i want 2 make thumnail and store in the folder
<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN” “
<html xmlns=”
<head>
<meta http-equiv=”Content-Type” content=”text/html; charset=iso-8859-1″ />
<title>Untitled Document</title>
</head>
<body>
<?php
if(isset($_POST[‘save’]))
{
$file_dir = “C:/Program Files/EasyPHP1-8/www/matri/Matri_Dev1.01/photo/”;
if (($HTTP_POST_FILES[‘fileupload’][‘type’]==”image/gif”) || ($HTTP_POST_
FILES[‘fileupload’][‘type’]==”image/bmp”) || ($HTTP_POST_FILES[‘fileupload’][‘type’]==”image/pjpeg”) || ($HTTP_POST_FILES[‘fileupload’][‘type’]==”image/jpeg”)) {
}
// image check for existing
if (file_exists($file_dir . $HTTP_POST_FILES[‘fileupload’][‘name’])) { echo “The file already exists – plz change file name in Upload Image 1 & upload <br>n”; exit; }
}
//$cont=0;
foreach($_FILES as $file_name => $file_array) {
$path=$file_array[‘tmp_name’];
$name=$file_array[‘name’];
$type=$file_array[‘type’];
$size=$file_array[‘size’];
//$image[$cont]=$name;
//$cont++;
if (is_uploaded_file($file_array[‘tmp_name’])) {
move_uploaded_file($file_array[‘tmp_name’],
“$file_dir/$file_array[name]”) or die (“Couldn’t copy”);
}
$conn = mysql_connect(“localhost”,”root”,””) or die(mysql_error());
mysql_select_db(“mms”,$conn) or die(mysql_error());
$today = date (“Y-m-d”);
//echo”$today”;
$sql = “INSERT INTO image values (”,’$name’,’ ‘,”,’$_POST[id]’,’$today’)”;
$result = mysql_query($sql, $conn) or die(mysql_error());
print “File Uploaded successfully!<br><br>”;
}
$conn = mysql_connect(“localhost”,”root”,””) or die(mysql_error());
mysql_select_db(“mms”,$conn) or die(mysql_error());
$list = “select * from image where image.u_id=’3′”;
$list = mysql_query($list) or die(mysql_error());
$count=mysql_num_rows($list);
if ($count > 0) {
$query = “SELECT imageone,imagetwo,imagethree FROM image,user WHERE image.u_id=’3′”;
$result = mysql_query($query) or die(‘Error, query failed’);
//while(list($imageone, $imagetwo, $imagethree) = mysql_fetch_array($result))//{
list($imageone, $imagetwo, $imagethree) = mysql_fetch_array($result);
?>
<img src=”photo/<?php echo $imageone; ?>” width=”200″ height=”200″/></img>
<?php
}else {
echo “<img src=”photo/noimage.jpg” width=”100″ height=”100″/>”;
}
?>
<form action=”testimg.php” enctype=”multipart/form-data” method=”POST”>
<input type=”hidden” name=”MAX_FILE_SIZE” value=”131072″>
Upload Image 1: <input type=”file” name=”fileupload”><br><br>
<input type=’hidden’ name=’id’ value=”3″><br />
<input type=’submit’ name=”save” value=’Upload File’>
</form>
</body>
</html>
[B]When I upload image 1944 * 2500 it doe’s not store in photo folder. If i upload image 150
HELP NEEDED