Forum Moderators: coopster

Message Too Old, No Replies

Photo Upload

         

outdoorxtreme1

2:53 pm on Nov 22, 2005 (gmt 0)

10+ Year Member



Am I able to modify this code so that I can upload multiple photos to MySQL?

<title>Simple file upload script</title>
</head>
<body>
<?php
if ($_REQUEST[completed] == 1) {
$source = "trip_log/pics";
move_uploaded_file($_FILES['filename']['tmp_name'],
"../$source/".$_FILES['filename']['name']);
// Following code to fix line ends
if (! eregi ('(gif¦jpg¦pdf)$',$_FILES['filename']['name'])) {
$fi = file("../$source/".$_FILES['filename']['name']);
$fi2 = fopen("../$source/".$_FILES['filename']['name'],"w");
foreach ($fi as $lne) {
$n = rtrim ($lne);
fputs ($fi2,"$n\n");
}
}
//
?>
Your file has been uploaded.
<?php } else {?>
<form enctype=multipart/form-data method=post>
<input type=hidden name=MAX_FILE_SIZE value=150000>
<input type=hidden name=completed value=1>
Choose file to send: <input type=file name=filename> and
<input type=submit></form><br>
<?php }?>
</body>
</html>

outdoorxtreme1

3:01 pm on Nov 22, 2005 (gmt 0)

10+ Year Member



Would actually like to be able to upload a number of pictures somehow and to be able to store the image path to each in the database.

willybfriendly

3:22 pm on Nov 22, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I am using something like this, which uploads as many as you want (4 in this case)

for($v=0;$v<4;$v++)//while there is a pic in the array...
{
if ($_FILES['userfile']['name'][$v] == "") //if name is blank
continue;//next iteration of for loop
$num = $num + 1;
$pic = "pic".($v+1);
$picname = $_FILES['userfile']['name'][$v];
if (move_uploaded_file($_FILES['userfile']['tmp_name'][$v], $imagepath . $_FILES['userfile']['name'][$v]))
{
$sql = "UPDATE Data SET $pic = '$picname' WHERE ID = '$ID'";
$result = mysql_query($sql)
or die("Failed updating photo in DB");
}
else
{
$msg .= "<strong>".$_FILES['userfile']['name'][$v]."</strong> did not upload!";
}
}//end of if editpics

In this instance I have already created fields in the DB for the subject,so there is an $ID that I have pulled out of the DB. You could just as easily use an INSERT statement I supppose.

WBF

outdoorxtreme1

3:37 pm on Nov 22, 2005 (gmt 0)

10+ Year Member



Would I be able to use this with the code above? I am new to php and not sure how to get this to work.

outdoorxtreme1

3:45 pm on Nov 22, 2005 (gmt 0)

10+ Year Member



Would I need 4 input fields?

outdoorxtreme1

5:34 pm on Nov 22, 2005 (gmt 0)

10+ Year Member



I changed the code from my original post. I have a form page and a submit page. Here is what I am trying to do but it doesn't seem to work. Can anyone help?

Here is the form page:
<?
if (isset($errmsg) &&!empty($errmsg)) {
echo '<div><font FACE="Arial, Helvetica, sans-serif" size="2" color=#FF0000>SORRY: There is a problem with information you have submitted:</font><br>';
echo '<ul>';
echo $errmsg;
echo '</ul>';
echo '<font FACE="Arial, Helvetica, sans-serif" size="2" color=#FF0000>Please complete your report and "Submit" again...<br></font><br></div>';
}
?>

<?
$today = getdate();
$day = $today['mday'];
$month = $today['mon'];
$year = $today['year'];
$mtharr = array("January","February","March","April","May","June","July","August","September","October","November","December");
?>

<form method="post" action="/trip_log/upload_submit.php">
<table>
<tr>
<td valign="top" id="fillinform">
<table WIDTH="450">

<tr>
<td valign="top" colspan="2">
<input type="hidden" name="triptype" value="ATV" />
<font FACE="Arial, Helvetica, sans-serif" size="1">
<strong>ATV Area:</strong><br />
<input type="text" size="29" maxlength="50" name="triplocation" value="<? echo $_POST['triplocation'];?>" />
<br />
</font>
</td>
</tr>

<tr>
<td valign="top" colspan="2">
<font FACE="Arial, Helvetica, sans-serif" size="1">
<strong>State:</strong><br />
<select name="state" size="1">

<option selected="selected" value=""></option>
<option value="OH">Ohio</option>
<option value="PA">Pennsylvania</option>
<option value="NY">New York</option>
<option value="WV">West Virginia</option>

</select>
<br />
</font>
</td>
</tr>

<tr>
<td valign="top" colspan="2">
<font FACE="Arial, Helvetica, sans-serif" size="1">
<strong>Miles Traveled:</strong><br />
<input type="text" size="29" maxlength="50" name="miles" value="<? echo $_POST['miles'];?>" />
<br />
</font>
</td>
</tr>

<tr>
<td valign="top" colspan="2"><strong>Trip Organizer:</strong><br />
<input type="text" size="29" maxlength="50"
name="triporganizer" value="<? echo $_POST['triporganizer'];?>" />
<br />
</td>
<td valign="top">

</td>
<td valign="top">

</td>
</tr>
<tr>
<td valign="top" colspan="2" style="white-space:nowrap;"><strong>Trip Start:</strong><br />
<select name="TSpickMonth" size="1">
<? for ($i=1;$i<=12;$i++) {?><? echo "<option value=\"$i\""; if ($i == $month) echo " selected"; echo ">" . $mtharr[$i-1] . "</option>"; } ?>
</select>

<select name="TSpickDay" size="1">
<? for ($i=1;$i<=31;$i++) {?><? echo "<option value=\"$i\""; if ($i == $day) echo " selected"; echo ">$i</option>"; } ?>
</select>

<select name="TSpickYear" size="1">
<? for ($i=2002;$i<=2010;$i++) {?><? echo "<option value=\"$i\""; if ($i == $year) echo " selected"; echo ">$i</option>"; } ?>
</select>

</td>
<td valign="top" colspan="2">

</td>
</tr>
<tr>
<td valign="top" colspan="2" style="white-space:nowrap;"><strong>Trip Finish:</strong><br />
<select name="TFpickMonth" size="1">
<? for ($i=1;$i<=12;$i++) {?><? echo "<option value=\"$i\""; if ($i == $month) echo " selected"; echo ">" . $mtharr[$i-1] . "</option>"; } ?>
</select>

<select name="TFpickDay" size="1">
<? for ($i=1;$i<=31;$i++) {?><? echo "<option value=\"$i\""; if ($i == $day) echo " selected"; echo ">$i</option>"; } ?>
</select>

<select name="TFpickYear" size="1">
<? for ($i=2002;$i<=2010;$i++) {?><? echo "<option value=\"$i\""; if ($i == $year) echo " selected"; echo ">$i</option>"; } ?>
</select>

</td>
<td valign="top" colspan="2"><br />
</td>
</tr>
<tr>
<td colspan="2" valign="top"><strong>Trip Report Author:</strong><br />
<input type="text" size="29" maxlength="50" name="author" value="<? echo $_POST['author'];?>" /> </td>
<td colspan="2" valign="top"><strong>Email:</strong><br />
<input type="text" size="29" maxlength="50" name="email" value="<? echo $_POST['email'];?>" /> </td>
</tr>
</table>
</td>
</tr></table>

<table>
<tr>
<td valign="top" id="fillinform">
<strong>Participant Names:</strong>
<table border="0" WIDTH="456">
<tr>

<td>
1 <input type="text" size="25" maxlength="50" name="p1" value="<? echo $_POST['p1'];?>" /><br>
2 <input type="text" size="25" maxlength="50" name="p2" value="<? echo $_POST['p2'];?>" /><br>
3 <input type="text" size="25" maxlength="50" name="p3" value="<? echo $_POST['p3'];?>" /><br>
4 <input type="text" size="25" maxlength="50" name="p4" value="<? echo $_POST['p4'];?>" /><br>
5 <input type="text" size="25" maxlength="50" name="p5" value="<? echo $_POST['p5'];?>" /><br>
6 <input type="text" size="25" maxlength="50" name="p6" value="<? echo $_POST['p6'];?>" /><br>
7 <input type="text" size="25" maxlength="50" name="p7" value="<? echo $_POST['p7'];?>" /><br>
8 <input type="text" size="25" maxlength="50" name="p8" value="<? echo $_POST['p8'];?>" /><br>
</td>

</tr>
</table>
</td>
</tr>
</table>

<table>
<tr>
<td valign="top" id="fillinform">
<table
border="0" WIDTH="456">
<tr>

<td>
Upload Picture 1: <INPUT NAME="pic1" TYPE="file"><br>
Upload Picture 2: <INPUT NAME="pic2" TYPE="file"><br>
Upload Picture 3: <INPUT NAME="pic3" TYPE="file"><br>
</td>
</tr>
</table>
</td>
</tr></table>

<table>
<tr>
<td valign="top" id="fillinform">
<strong>Type your trip report below:</strong><br />
<textarea name="report" rows="15" cols="55" wrap="on" class="input350"><? echo $_POST['report'];?></textarea>
<br>
<center>
<input id="Submit" type="submit" style="font-size:smaller;width:7em;" name="screen" value="Submit">
</center>
</td>
</tr>
</TABLE>
<TABLE WIDTH="273">
<TR>
<td valign="top">
<p>

</p>
</td>
</tr>
</table>

outdoorxtreme1

5:35 pm on Nov 22, 2005 (gmt 0)

10+ Year Member



Here is the Submit page:

<?
// initialize var for storing possible error messages
$errmsg = '';

// check rivername
if (empty($_POST['triplocation'])) {
$errmsg .= '<font color=#FF0000><li>Your report has no [ATV area]</li></font><br>';
}

// check state
if (empty($_POST['state'])) {
$errmsg .= '<font color=#FF0000><li>Your report has no [state]</li></font><br>';
}

// check author
if (empty($_POST['author'])) {
$errmsg .= '<font color=#FF0000><li>Please identify the [trip report author]</li></font><br>';
}

// check report
if (empty($_POST['report'])) {
$errmsg .= '<font color=#FF0000><li>Please fill in your [trip report]</li></font><br>';
}

// check to see if the file size is 250KB or less
if ($pic1_size >250000){
$errmsg .='<font color=#FF0000><li>Your uploaded file size is more than 250KB so please reduce the file size and then upload. Visit the help page to know how to reduce the file size.</li></font><br>';
$file_upload="false";}

// check to see if the file size is 250KB or less
if ($pic2_size >250000){
$errmsg .='<font color=#FF0000><li>Your uploaded file size is more than 250KB so please reduce the file size and then upload. Visit the help page to know how to reduce the file size.</li></font><br>';
$file_upload="false";}

// check to see if the file size is 250KB or less
if ($pic3_size >250000){
$errmsg .='<font color=#FF0000><li>Your uploaded file size is more than 250KB so please reduce the file size and then upload. Visit the help page to know how to reduce the file size.</li></font><br>';
$file_upload="false";}

// check to see if anything was placed in our error var, meaning there was an error
if (!empty($errmsg)) {
include 'upload_form.php';

} else {
$host = " ";
$user = " ";
$pass = " ";
$dbname = " ";

$connection = mysql_connect($host,$user,$pass) or die (mysql_errno().": ".mysql_error()."<BR>");
mysql_select_db($dbname);

$add="trip_log/pics/$pic1_name"; // the path with the file name where the file will be stored, upload is the directory name.

if(move_uploaded_file ($pic1, $add)){
// do your coding here to give a thanks message or any other thing.
}else{echo "Failed to upload file Contact Site admin to fix the problem";}

$add="trip_log/pics/$pic2_name"; // the path with the file name where the file will be stored, upload is the directory name.

if(move_uploaded_file ($pic2, $add)){
// do your coding here to give a thanks message or any other thing.
}else{echo "Failed to upload file Contact Site admin to fix the problem";}

$add="trip_log/pics/$pic3_name"; // the path with the file name where the file will be stored, upload is the directory name.

if(move_uploaded_file ($pic3, $add)){
// do your coding here to give a thanks message or any other thing.
}else{echo "Failed to upload file Contact Site admin to fix the problem";}

$startdate = mktime(0,0,0,$TSpickMonth,$TSpickDay,$TSpickYear);
$enddate = mktime(0,0,0,$TFpickMonth,$TFpickDay,$TFpickYear);

$sql_query = mysql_query("INSERT INTO trip_log(triptype, triplocation, state, rivercondition, riverclass, triporganizer, GaugeFT, GaugeCFS, GaugeID, author, email, p1, p2, p3, p4, p5, p6, p7, p8, report, photolink, videolink1, videolink2, videolink3, miles, startdate, enddate) VALUES ('$triptype', '$triplocation', '$state', '$rivercondition', '$riverclass', '$triporganizer', '$GaugeFT', '$GaugeCFS', '$GaugeID', '$author', '$email', '$p1', '$p2', '$p3', '$p4', '$p5', '$p6', '$p7', '$p8', '$report', '$photolink', '$videolink1', '$videolink2', '$videolink3', '$miles', '$startdate', '$enddate')")
or die (mysql_error());

header("Location: /trip_log.php");
}
?>

willybfriendly

6:14 pm on Nov 22, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Take a look here - [webmasterworld.com...]

Nice example of uploading multiple files, with a nice explanation to boot.

WBF

outdoorxtreme1

3:04 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



I am trying the code that you suggested and I am getting an error in the loademup.php page. Here is the error I am getting.

Parse error: parse error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in /home/neohoutd/public_html/trip_log/loademup.php on line 34

Any clue why?

LeChuck

3:15 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



check your semicolons, $'s and brackets.

willybfriendly

3:17 pm on Nov 28, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Try replacing that line with

print "<strong>".$_FILES['userfile']['name'][$q]."</strong> did not upload!";

WBF

outdoorxtreme1

3:25 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



Seem to be a problem with these lines of code but I don't see anything wrong.

if (move_uploaded_file($_FILES['userfile']['tmp_name'][$q], $uploaddir . $new_pic)){
$sql = "INSERT INTO `pics` ( `pic_id` , `name` , `descrip` )VALUES ('$new_id', NULL , NULL);";
mysql_query($sql);
} else {
print "<strong>$_FILES['userfile']['name'][$q]</strong> did not upload!";
}

outdoorxtreme1

3:33 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



That seemed to work. It made it another step but now I get about 6 error messages. I have the permissions set for writing to the folder.

Warning: move_uploaded_file(/home/username/public_html/pics/): failed to open stream: No such file or directory in /home/neohoutd/public_html/trip_log/loademup.php on line 30

Warning: move_uploaded_file(): Unable to move '/tmp/phpGmE2AV' to '/home/username/public_html/pics/' in /home/neohoutd/public_html/trip_log/loademup.php on line 30
next_button.gif did not upload!
Warning: getimagesize(/home/username/public_html/pics/): failed to open stream: No such file or directory in /home/neohoutd/public_html/trip_log/loademup.php on line 39

Warning: imagecreatefromjpeg(/home/username/public_html/pics/): failed to open stream: No such file or directory in /home/neohoutd/public_html/trip_log/loademup.php on line 53

Warning: imagecopyresized(): supplied argument is not a valid Image resource in /home/neohoutd/public_html/trip_log/loademup.php on line 55

Warning: imagejpeg(): Unable to open '/home/username/public_html/pics/thumbs/' for writing in /home/neohoutd/public_html/trip_log/loademup.php on line 56

outdoorxtreme1

3:55 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



I modified this line to try and fix it but still errors.

$uploaddir = '/home/neohoutd/public_html/pics/';

outdoorxtreme1

4:31 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



Are these erros because I don't have GD image library installed. If so how do I go about installing it?

outdoorxtreme1

4:42 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



I checked if I had GD image library installed and it seems that I do. I'm not sure what else it could be. Anyone have any ideas?

outdoorxtreme1

5:31 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



Here is the code and the error messages I get.

<html>
<head><title>Enter Name and Descriptions of Pics</title></head>
<body>
<h1>Enter Name and Descriptions of Pics</h1>
<form action="view.php" method="post">
<?php
$host = " ";
$user = " ";
$pass = " ";
$dbname = " ";

$dbh=mysql_connect($host,$user,$pass) or die ('I cannot connect to the database.');
mysql_select_db($dbname);

$uploaddir = '/home/neohoutd/public_html/pics/';
$tot = count($userfile);
$num = 0;
for($q=0;$q<$tot;$q++){

if ($_FILES['userfile']['name'][$q] == "") continue;
$num = $num + 1;
$sql = "SELECT pic_id FROM pics ORDER BY pic_id DESC LIMIT 1";
$result = mysql_query($sql);

while($i = mysql_fetch_array($result)){
$new_id = $i['pic_id'] + 1;
$new_pic = "$new_id.jpg";
}

if (move_uploaded_file($_FILES['userfile']['tmp_name'][$q], $uploaddir . $new_pic)) {
$sql = "INSERT INTO `pics` ( `pic_id` , `pic_name` , `descrip` )VALUES ('$new_id', NULL , NULL);";
mysql_query($sql);
} else {
print "<strong>".$_FILES['userfile']['name'][$q]."</strong> did not upload!";
}

$new_thumb = "thumbs/$new_pic";
$sourcefile = "$uploaddir$new_pic";
$picsize = getimagesize("$sourcefile");
$source_x = $picsize[0];
$source_y = $picsize;

if ($source_x > $source_y){
$dest_x = 200;
$dest_y = 150;
} else {
$dest_x = 150;
$dest_y = 200;
}

$targetfile = "$uploaddir$new_thumb";
$jpegqual = 75;
$source_id = imagecreatefromjpeg("$sourcefile");
$target_id = imagecreatetruecolor($dest_x, $dest_y);
$target_pic = imagecopyresized($target_id,$source_id,0,0,0,0,$dest_x,$dest_y,$source_x,$source_y);
imagejpeg($target_id,"$targetfile",$jpegqual);
?>
<div style="clear: both;">
<a href="/pics/<?=$new_pic?>">
<img src="/pics/<?=$new_thumb?>" style="float: left" />
</a>
<strong><?=$_FILES['userfile']['name'][$q]?></strong><br /><br />
<strong>Name:</strong><br />
<input type="text" name="pic_name[<?=$num?>]" /><br /><br />
<strong>Description:</strong><br />
<textarea name="descrip[<?=$num?>]"></textarea>
<input type="hidden" name="pic_id[<?=$num?>]" value="<?=$new_id?>" />
</div>
<?php
}
?>
<input type="submit" value="Click to Save Descriptions" />
</form>
</body>
</html>


Warning: move_uploaded_file(/home/neohoutd/public_html/pics/): failed to open stream: Is a directory in /home/neohoutd/public_html/trip_log/loademup.php on line 30

Warning: move_uploaded_file(): Unable to move '/tmp/phpxnZxJO' to '/home/neohoutd/public_html/pics/' in /home/neohoutd/public_html/trip_log/loademup.php on line 30
virga2bagandpack.jpeg did not upload!
Warning: getimagesize(): Read error! in /home/neohoutd/public_html/trip_log/loademup.php on line 39

Warning: imagecreatefromjpeg(): gd-jpeg: JPEG library reports unrecoverable error: in /home/neohoutd/public_html/trip_log/loademup.php on line 53

Warning: imagecreatefromjpeg(): '/home/neohoutd/public_html/pics/' is not a valid JPEG file in /home/neohoutd/public_html/trip_log/loademup.php on line 53

Warning: imagecopyresized(): supplied argument is not a valid Image resource in /home/neohoutd/public_html/trip_log/loademup.php on line 55

Warning: imagejpeg(): Unable to open '/home/neohoutd/public_html/pics/thumbs/' for writing in /home/neohoutd/public_html/trip_log/loademup.php on line 56

outdoorxtreme1

9:03 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



What does anyone think of this line? Could I have it wrong?

$uploaddir = '/home/neohoutd/public_html/pics/';

willybfriendly

9:06 pm on Nov 28, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



next_button.gif did not upload!

Warning: imagecreatefromjpeg(/home/username/public_html/pics/): failed to open stream: No such file or directory in /home/neohoutd/public_html/trip_log/loademup.php on line 53

There is one problem. You are trying to create from jpeg using a gif.

To debug what is going on I would advise that you echo all of your variables to be sure that they contain what you think they do. It might be a simple path problem.

WBF

outdoorxtreme1

9:07 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



I get the same errors with a jpeg file

outdoorxtreme1

9:25 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



I echoed all my variables. Seemed to be ok. I'm not too sure on this path.

$uploaddir = '/home/neohoutd/public_html/pics/';

I tried changing it to

$uploaddir = './pics/';

jatar_k

9:32 pm on Nov 28, 2005 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



always start with your first error (top) and work from there

your first error seems to be

Warning: move_uploaded_file(/home/neohoutd/public_html/pics/): failed to open stream: Is a directory in /home/neohoutd/public_html/trip_log/loademup.php on line 30

so the move_uploaded _file is dying, which is the reason for everything else not working

this is the piece of code you need to figure out

if (move_uploaded_file($_FILES['userfile']['tmp_name'][$q], $uploaddir . $new_pic)) {
$sql = "INSERT INTO `pics` ( `pic_id` , `pic_name` , `descrip` )VALUES ('$new_id', NULL , NULL);";
mysql_query($sql);
} else {
print "<strong>".$_FILES['userfile']['name'][$q]."</strong> did not upload!";
}

also you should put an exit(); or die(); in that else statement. Once you print the error you need to stop script execution

outdoorxtreme1

9:45 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



Are the values that I am trying to query not right?

jatar_k

10:05 pm on Nov 28, 2005 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



this seems fine

move_uploaded_file($_FILES['userfile']['tmp_name'][$q], $uploaddir . $new_pic)

but that doesn't mean all of those variables are properly constructed

echo them and see if they are right, that paths exist, that it actually is getting something in the $_FILES array, etc

willybfriendly

10:07 pm on Nov 28, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



echo $_FILES['userfile']['tmp_name'][$q];

and

echo $uploaddir . $new_pic;

just to see what is there.

You might also want to confirm that you have a tmp folder that the uploads are going to. I know of at least one host that has disabled this for security reasons, causing the webmaster to have to create a writable folder (outside of document root) to receive file uploads.

WBF

outdoorxtreme1

10:29 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



Doesn't seem to be echoing the userfile.

If I put

echo $_FILES['userfile'];

it echos the word "Array"

outdoorxtreme1

10:55 pm on Nov 28, 2005 (gmt 0)

10+ Year Member



If I do a

print_r($_FILES);

That seems to print the array info. I really don't know what is wrong. Here is what I get.

Array ( [userfile] => Array ( [name] => Array ( [0] => GO_logo_little.jpeg [1] => kayak8NEW.jpg [2] => kayak8.jpg [3] => neoh2.jpg [4] => kayaking.jpg [5] => neoh2.jpg ) [type] => Array ( [0] => image/pjpeg [1] => image/pjpeg [2] => image/pjpeg [3] => image/pjpeg [4] => image/pjpeg [5] => image/pjpeg ) [tmp_name] => Array ( [0] => /tmp/phpTWEUhw [1] => /tmp/phpfuws68 [2] => /tmp/phpPyu3UM [3] => /tmp/phpFLv5us [4] => /tmp/php1sdNa9 [5] => /tmp/php3FoQ1P ) [error] => Array ( [0] => 0 [1] => 0 [2] => 0 [3] => 0 [4] => 0 [5] => 0 ) [size] => Array ( [0] => 15382 [1] => 12543 [2] => 35928 [3] => 17634 [4] => 3198 [5] => 17634 ) ) )

willybfriendly

11:08 pm on Nov 28, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



It tells you that you have files in the array. Are they in the tmp folder?

Did you echo $uploaddir . $new_pic?

WBF

outdoorxtreme1

12:05 am on Nov 29, 2005 (gmt 0)

10+ Year Member



Ok, I got the errors to go away but now it doesn't show the thumbnail.

outdoorxtreme1

12:14 am on Nov 29, 2005 (gmt 0)

10+ Year Member



I think it is diplaying something but it a bunch of vertical gray bars. Any thoughts?
This 33 message thread spans 2 pages: 33