Thanks here is the main code which uploads it :
function do_upload () {
global $uploadfile, $uploadfile_name, $uploadfile_type, $uploadfile_size;
global $local_file, $error_msg;
//if file specified isn't a gif/jpeg, output error message
if (($uploadfile_type != "image/gif") && ($uploadfile_type != "image/jpeg")
&& ($uploadfile_type != "image/pjpeg"))
{ $error_msg .= "Your file is not a web graphic (GIF/JPG).\n"; }
// Change $upload_dir to the directory that you have write permission (777) for on your server
$upload_dir = "tempphotos";
$local_uploadfile = "$upload_dir/$uploadfile_name";
//if there's no error, print info about the uploaded file
if (!$error_msg && copy($uploadfile, $local_uploadfile)){
echo "Redirecting back to site please wait...... ";
echo" <script>
window.location=\"cars.asp\"
</script> ";
}
Cheers