I've read a thread about this subject but I stil have one more problem in my program. One of the variabels that will be send is a file ( file attachment). In page A, there are 2 submit button, "submit" and "preview".

code :
if (isset($preview)){
echo "<FORM action=\"file.php\" method=\"post\" >";
while(list($key,$val) = each ($HTTP_POST_VARS)) {
if($key != "preview"){
if ($key!="password" and $key!="username"){echo $key."=".$val;}
printf('<input type="hidden" name="%s" value="%s">', $key, $val);
}
echo "<INPUT TYPE=\"submit\" name =\"submit\">";
}
else
{ do ...
}
when I click submit button, there is an error in reading that file. Can you help me ??

<Edited by traitoknow on 11-27-2000 at 09:28 PM>