hi all
i am doing a simple upload script of the sort i do all the time below is the script that dosen't work
here is the html that sends the stuff to to my script
[CODE=html]
<html>
<head>
<title>Untitl ed Document</title>
</head>
<body>
<form action="process .php" method="post" enctype="multip art/form-data">
<input type="file" name='imagefile '><br>
<input type="submit">
</form>
</body>
</html>
[/CODE]
and here is process.php in its entirety
[PHP]
<?
include 'connect.php';
mysql_select_db ($database, $cms);
$label = $_POST['label'];
$result = mysql_query("SE LECT * FROM `counter`");
$row=mysql_fetc h_row($result);
$i = $row[0];
$i++;
$save = "$i.jpg";
move_uploaded_f ile($_FILES['imagefile']['tmp_name'], $save);
?>
[/PHP]
i have done var dump on $_FILES and everything seems fine, i have printed out $save and the correct value is there, i put double quotes around the $save variable in the function call once to see if that helped but still to no avail, i don't know what is going on this is so simple it is totaly ridiculas, by the way $i = 2 in this case,
thanks for help
eric
i am doing a simple upload script of the sort i do all the time below is the script that dosen't work
here is the html that sends the stuff to to my script
[CODE=html]
<html>
<head>
<title>Untitl ed Document</title>
</head>
<body>
<form action="process .php" method="post" enctype="multip art/form-data">
<input type="file" name='imagefile '><br>
<input type="submit">
</form>
</body>
</html>
[/CODE]
and here is process.php in its entirety
[PHP]
<?
include 'connect.php';
mysql_select_db ($database, $cms);
$label = $_POST['label'];
$result = mysql_query("SE LECT * FROM `counter`");
$row=mysql_fetc h_row($result);
$i = $row[0];
$i++;
$save = "$i.jpg";
move_uploaded_f ile($_FILES['imagefile']['tmp_name'], $save);
?>
[/PHP]
i have done var dump on $_FILES and everything seems fine, i have printed out $save and the correct value is there, i put double quotes around the $save variable in the function call once to see if that helped but still to no avail, i don't know what is going on this is so simple it is totaly ridiculas, by the way $i = 2 in this case,
thanks for help
eric
Comment