Eggzorcist Posted January 1, 2010 Share Posted January 1, 2010 How can I make my script so I can send a mail, and if that mail is sent successfully, then it goes to header('Location: index.php') ? I tried but I keep getting an error or it doesnt do anything... Any help would be great, thanks Quote Link to comment https://forums.phpfreaks.com/topic/186880-mail-header/ Share on other sites More sharing options...
Daniel0 Posted January 1, 2010 Share Posted January 1, 2010 if (mail(/* stuff here */)) { header('Location: index.php'); exit; } else { echo 'something broke'; } Quote Link to comment https://forums.phpfreaks.com/topic/186880-mail-header/#findComment-986905 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.