PasteSite is open to the public, but with limited features. Register to be able to modify access rights, track your pastes and more...
If you prefer reading light text on a dark background to dark text on a light background, then you might want to try the dark theme.
"Re: Re: Re: Re: Re: Re: Re: Re: #4915" by Anonymous [PHP]Actions: |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
<form> <p>First Name:</p><input name="fname" class="name" size="40" maxlength="255" type="text" /> <p>Last Name:</p><input name="lname" class="name" size="40" maxlength="255" type="text" /> <p>Email Adress:</p><input name="email" class="email" size="40" maxlength="255" type="text" /> <p>Subject:</p><input name="subject" id="subject" size="40" maxlength="255" type="text" /> <p>Enter Text:</p><input name="content" id="content" style="width: 500px; height: 200px;" type="text" /> <input type="submit" name="submit" value="submit" /> </form> if(isset($_POST['fname']) && !preg_match('/[^a-zA-Z-]/',$_POST['fname'].$_POST['lname']) && filter_var($_POST['email'], FILTER_VALIDATE_EMAIL) && !preg_match('/[^a-zA-Z0-9 ]/',$_POST['subject']) && strlen($_POST['content']) <= 400){ if(@mail($_POST['email'], $_POST['subject'], $_POST['content'], "From: ".$_POST['fname']." ".$_POST['lname']." <".$_POST['email'].">")){ echo "success"; } else{ echo "random mail failure"; } } elseif(isset($_POST['fname'])) echo "incorrect details"; |