/ Published in: PHP

the user sees the confirmation page immedeateley. this is helpful if the mail() function takes some time
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
<? ?><!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html><head><meta http-equiv="content-type" content="text/html;charset=utf-8"> </head><body> <? ?> <h2>Thank you for sending the form!</h2> <? global $body_for_callback; $body_for_callback = $_POST["name"] ." has filled in the form."; function mail_callback() { global $body_for_callback; } else: ?> <form id="orderform" action="#" method="post" name="form1"> <input type="text" name="name"> <input type="submit" name="go" value="send form"> </form> <? endif; ?> </body></html> <? ?>
Comments
