$db = Database::obtain(DB_SERVER, DB_USER, DB_PASS, DB_DATABASE); $db->connect(); $s = new Stories('member', BASE_DOMAIN, ''); $sl = $s->getStoryCreator($story_id); foreach ($sl as $s) { $to_email = $s['email']; $first_name = $s['first_name']; $creator_id = $s['master_id']; } if ($mode == 'share') { $to_email = $_REQUEST['email']; // echo "Share ".$to_email . "<br />"; } //send to db $se = new Stories('member', BASE_DOMAIN, ''); $se->sendEmail($to_email, $from, $message, $story_id, $sender_id, $creator_id, $from); if ($mode != 'share') { $se->updateClaim($story_id, '1', $sender_id); } //register as claimer in interest $mail = new PHPMailer(); // defaults to using php "mail()" $mail->IsSendmail(); // telling the class to use SendMail transport $body = "<body style=\"margin: 10px;\">\n<div style=\"width: 640px; font-family: Arial, Helvetica, sans-serif; font-size: 11px;\">\n<div align=\"center\"><img src=\"http://www.getpublicized.com/pg/img/p-story.png\" style=\"height: 90px; width: 90px\"></div><br>\n<br>\n" . $first_name . " Interest Email<br>\n<br>\n\n<br>\nthis person is interested in this story: \n<a href=\"" . $url . "\" >client story</a>\n<br />\nMessage:<br />\n<blockquote>" . $message . "</blockquote>\n</div>\n</body>\n"; $body = eregi_replace("[\\]", '', $body); $mail->AddReplyTo($from, ""); $mail->SetFrom($from, 'Get-P User'); $address = $to_email; $mail->AddAddress($address, ""); $mail->Subject = "GetP - Interest Indicated";