I have this code after a user submits a form with name, description and
image file upload fields:
images/people/preview is simply a unix link to /tmp/phptempimg-ian.grant

The problem is, when this script is run, the image show is that from the
previous operation. If you refresh the page, the correct image is displayed.

How can I fix this without refreshing the page?


if (is_uploaded_file($picture)) {
    rename($picture, "/tmp/phptempimg-ian.grant");
 if ($picture!="none")

$picture="/tmp/phptempimg-ian.grant";$picture_src="images/people/preview"; }
else { $picture_src="images/people/none.gif"; }

 echo "You are about to add the following member profile to the team
profiles database:<br><br>\n";

 echo  "<b>Name:</b> $name<br>\n";
 echo  "<b>Description:</b> $desc<br>\n";
 echo  "<b>Picture:</b> <img src=\"$picture_src\" alt=\"$name\"
width=\"110\" height=\"121\"><br>\n";


PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to