Exemplo n.º 1
0
 public function executeAddJob(sfWebRequest $request)
 {
     $jobId = $request->getParameter("id");
     $job = JobPeer::retrieveByPK($jobId);
     $profile = $this->getUser()->getProfile();
     $to = "*****@*****.**";
     $subject = $profile->getFirstName() . " " . $profile->getLastName() . " is requestting to be added to job " . $job->getEvent();
     mail($to, $subject, $subject);
     JobPeer::addEmailLogMessage($jobId, "Request to be added", "*****@*****.**");
 }
Exemplo n.º 2
0
 public function executeEmail(sfWebRequest $request)
 {
     $to = $request->getParameter("to");
     // $from = "From: " . $request->getParameter("from");
     $from = "From: photo@tufts.edu";
     $subject = $request->getParameter("subject");
     $body = $request->getParameter("body");
     $this->sent = mail($to . ", photo@tufts.edu", $subject, $body, $from);
     $jobId = $request->getParameter("jobId");
     JobPeer::addEmailLogMessage($jobId, ucfirst($subject), $to);
 }