Do you already know how to handle file uploads? If so, once you submit the form, you could use code like this:
if(!empty($_FILES['myFile']['tmp_name'])) {
$im = imagecreatefromjpeg(ini_get('upload_tmp_dir').$_FILES['myFile']['tmp_name'])
imageinterlace($im, 0);
imagejpeg($_SERVER['DOCUMENT_ROOT'].'/upload/'.$_FILES['myFile']['name'], 100);
unlink(ini_get('upload_tmp_dir').$_FILES['myFile']['tmp_name']);
}
NOTE: I haven't tested the above script. Also, you should change '/upload/' to the appropriate directory.