I'm very new to php.
For a website I created I want the users to be able to sent a string to an email address and when they are done, to be redirected to another page (html-page).
I created a html page with a form that calls a php page. Both scripts work perfectly, but for now they just give a message after sending.
How can I replace the "echo" to make the script go to another html-page?
I'm learning from th "php5 and MySQL bible", but i can't find this anywhere... yet
<form method="post" action="masc.php">
A name for our mascotte...<br>
<input type="text" size="30" name="Mascotte"><br>
<input type="submit" name="Submit" value="Send"><br>
</form><?php
$Mascotte = $_POST['Mascotte'];
$formsent = mail('mascotte@email.com','Name Mascotte',$Mascotte);
if ($formsent) {
echo "Thanks!";
} else {
echo "try again";
}
?>




Reply With Quote

Bookmarks