Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $action=$_REQUEST['action'];
- if ($action=="")
- {
- ?>
- <form action="" method="POST" enctype="multipart/form-data">
- <input type="hidden" name="action" value="submit">
- Your name:<br>
- <input name="name" type="text" value="" size="30"/><br>
- Your email:<br>
- <input name="email" type="text" value="" size="30"/><br>
- Your message:<br>
- <textarea name="message" rows="7" cols="30"></textarea><br>
- <input type="submit" value="Verzend Mail"/>
- </form>
- <?php
- }
- else
- {
- $name=$_REQUEST['name'];
- $email=$_REQUEST['email'];
- $message=$_REQUEST['message'];
- if (($name=="")||($email=="")||($message==""))
- {
- echo "Je moet alles invullen!";
- }
- else{
- $from="From: $name<$email>\r\nReturn-path: $email";
- $subject="Bericht die je verzend";
- mail("brian53@live.nl", $subject, $message, $from);
- echo "Email Verzonden!";
- }
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement