$msg\n"); } } if ($process) { $sendername = ereg_replace("[<>|\"\'\|]", "", $sendername); $ok = require_field($sendername, $sendernameerr, "Your Name", $ok); $ok = require_field($comments, $commentserr, "A Personal Note", $ok); $ok = require_field($subject, $subjecterr, "Subject", $ok); $ok = verify_email($senderemail, $senderemailerr, 1, $ok) ; $ok = verify_email($recemail, $recemailerr, 1, $ok) ; if ($ok) { $thejoke = ""; if ($targetdb) { $jokeInfo = getAJoke($jokeFileDirectory .$targetdb.".db",$n); $thejoke = $jokeInfo['joke']; } $message = "" . "\n" . " \n". nl2br(htmlspecialchars(stripslashes($comments))) . "\n



\n" . $thejoke . "\n


\n" . "\nThis joke came from the ". "$targetddesc section of " . "Mefco's Random Joke Server.

" . "Help bring a smile to the world. Please forward this message to five of your friends.

\n" . "For more jokes, or to subscribe to our mailing list, please visit us at www.RandomJoke.com.\n". "

This e-mail has been sent to you because we received a " . "specific request on our web site to send you this particular joke. " . "We apologize if you have received this in error.\n" . "

Copyright © " . "2000 Mefco, Inc. All rights reserved." . "\n\n" ; $mailcmd = "/usr/sbin/sendmail -f " . EscapeShellCmd($senderemail) . " " . EscapeShellCmd($recemail); if ($docc) { $mailcmd = $mailcmd . " " . EscapeShellCmd($senderemail); } $mp = popen($mailcmd, "w"); fputs($mp, "From: \"$sendername\" <$senderemail>\n"); fputs($mp, "To: $recemail\n"); if ($docc) { fputs($mp, "CC: \"$sendername\" <$senderemail>\n"); } fputs($mp, "Subject: ". stripslashes($subject) . "\n"); fputs($mp, "Content-Type: text/html; charset=\"us-ascii\"\n"); fputs($mp,"\n"); fputs($mp, "$message\n"); pclose($mp); setcookie("MailJokeFromName", $sendername); setcookie("MailJokeFromEmail", $senderemail); setcookie("MailJokeSubject", stripslashes($subject)); setcookie("MailJokeNote", stripslashes($comments)); header("Location: thankyou.php?db=$targetdb"); $fd = fopen(getenv("DOCUMENT_ROOT")."/../submissions/mailedjokes.log", "a"); $sendername = make_safe_for_tsv($sendername); $subject = make_safe_for_tsv(stripslashes($subject)); $comments = make_safe_for_tsv(stripslashes($comments)); fputs($fd, "$sendername\t$senderemail\t$recemail\t$subject\t$comments\t$targetdb\t$n\t". getenv(REMOTE_HOST) . "\t" . getenv(REMOTE_ADDR) . "\t" . date("m/d/y\tH:i:s") . "\n"); fclose($fd); } } else { if ($comments=="") { if($MailJokeNote != "") { $comments =$MailJokeNote; } else { $comments ="I saw this joke on http://www.RandomJoke.com/ and thought you might enjoy it."; } } if ($subject=="") { if($MailJokeSubject != "") { $subject =$MailJokeSubject; } else { $subject ="Funny joke from RandomJoke.com"; } } if ($sendername=="" && $MailJokeFromName !="") { $sendername = $MailJokeFromName; } if ($senderemail=="" && $MailJokeFromEmail !="") { $senderemail = $MailJokeFromEmail; } } ?> Mefco's Random Joke Server- Mail a Joke to a Friend
Mefco's Random Joke Server

Mefco's 
    Random Joke Server


home
joke topics
funny stories
submit a joke
mailing list

advertise
about us
Prestige Mall

We would not be here without your support. If you enjoy our jokes, please make a PayPal donation to us by clicking on the small logo above. Please give whatever you think appropriate.

Mefco's 
    Random Joke Server

send a joke

Share the humor. Mail this joke to a friend!

When you fill out this form we will send the joke you were viewing to a friend via E-Mail. You can even write a personal note to go along with the joke.

You will be listed as the sender of the E-Mail, and we will tell your friend how to find our site. Please feel free to change the Subject and Personal Note fields. If you don't change them the text shown below will be used.

Don't worry. We will not add your E-Mail address, or your friend's E-Mail address to any mailing list.

All fields are required.

 Your Name:  
 Your E-Mail Address:  
 Your Friend's E-Mail Address:  
 Subject for E-Mail Message:  
 Personal Note:  
   > Also send yourself a copy of the joke

Privacy|Mefco's Random Joke Server

home | advertise | about us
joke topics | funny stories | submit a joke | contributors
prestige mall | mailing list

Copyright © 2000 Mefco, Inc., All rights reserved. E-mail: info@randomjoke.com
Design by Neuco Image Group, Inc.
"Mefco" and "Mefco's Random Joke Server" are trademarks of Mefco, Inc.
Privacy Policy       Disclaimer