Advertisement
Guest User

Untitled

a guest
Feb 17th, 2020
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.82 KB | None | 0 0
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  2. "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  4. <head>
  5. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  6. <title>Aliens Abducted Me - Report an Abduction</title>
  7. <link rel="stylesheet" type="text/css" href="style.css" />
  8. </head>
  9. <body>
  10. <h2>Aliens Abducted Me - Report an Abduction</h2>
  11.  
  12. <p>Share your story of alien abduction:</p>
  13. <form method="post" action="mailto:owen@aliensabductedme.com">
  14. <label for="firstname">First name:</label>
  15. <input type="text" id="firstname" name="firstname" /><br />
  16. <label for="lastname">Last name:</label>
  17. <input type="text" id="lastname" name="lastname" /><br />
  18. <label for="email">What is your email address?</label>
  19. <input type="text" id="email" name="email" /><br />
  20. <label for="whenithappened">When did it happen?</label>
  21. <input type="text" id="whenithappened" name="whenithappened" /><br />
  22. <label for="howlong">How long were you gone?</label>
  23. <input type="text" id="howlong" name="howlong" /><br />
  24. <label for="howmany">How many did you see?</label>
  25. <input type="text" id="howmany" name="howmany" /><br />
  26. <label for="aliendescription">Describe them:</label>
  27. <input type="text" id="aliendescription" name="aliendescription" size="32" /><br />
  28. <label for="whattheydid">What did they do to you?</label>
  29. <input type="text" id="whattheydid" name="whattheydid" size="32" /><br />
  30. <label for="fangspotted">Have you seen my dog Fang?</label>
  31. Yes <input id="fangspotted" name="fangspotted" type="radio" value="yes" />
  32. No <input id="fangspotted" name="fangspotted" type="radio" value="no" /><br />
  33. <img src="fang.jpg" width="100" height="175"
  34. alt="My abducted dog Fang." /><br />
  35. <label for="other">Anything else you want to add?</label>
  36. <textarea id="other" name="other"></textarea><br />
  37. <input type="submit" value="Report Abduction" name="submit" />
  38. </form>
  39. </body>
  40. </html>
  41.  
  42.  
  43. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  44. "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  45. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  46. <head>
  47. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  48. <title>Aliens Abducted Me - Report an Abduction</title>
  49. </head>
  50. <body>
  51. <h2>Aliens Abducted Me - Report an Abduction</h2>
  52.  
  53. <?php
  54. $name = $_POST['firstname'] . ' ' . $_POST['lastname'];
  55. $when_it_happened = $_POST['whenithappened'];
  56. $how_long = $_POST['howlong'];
  57. $how_many = $_POST['howmany'];
  58. $alien_description = $_POST['aliendescription'];
  59. $what_they_did = $_POST['whattheydid'];
  60. $fang_spotted = $_POST['fangspotted'];
  61. $email = $_POST['email'];
  62. $other = $_POST['other'];
  63.  
  64. $to = 'owen@aliensabductedme.com';
  65. $subject = 'Aliens Abducted Me - Abduction Report';
  66. $msg = "$name was abducted $when_it_happened and was gone for $how_long.\n" .
  67. "Number of aliens: $how_many\n" .
  68. "Alien description: $alien_description\n" .
  69. "What they did: $what_they_did\n" .
  70. "Fang spotted: $fang_spotted\n" .
  71. "Other comments: $other";
  72. mail($to, $subject, $msg, 'From:' . $email);
  73.  
  74. echo 'Thanks for submitting the form.<br />';
  75. echo 'You were abducted ' . $when_it_happened;
  76. echo ' and were gone for ' . $how_long . '<br />';
  77. echo 'Number of aliens: ' . $how_many . '<br />';
  78. echo 'Describe them: ' . $alien_description . '<br />';
  79. echo 'The aliens did this: ' . $what_they_did . '<br />';
  80. echo 'Was Fang there? ' . $fang_spotted . '<br />';
  81. echo 'Other comments: ' . $other . '<br />';
  82. echo 'Your email address is ' . $email;
  83. ?>
  84.  
  85. </body>
  86. </html>
  87.  
  88.  
  89. form label { display: inline-block; width: 225px;
  90. font-weight: bold;
  91. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement