public function EnviaMissatgeGlobalHospici() { $ADMIN = OptionsPeer::getString('MAIL_ADMIN', $this->getSiteId()); //Carreguem el correu de l'administrador $MAILS = UsuarisPeer::getAdminMails(); //Carreguem els mails dels administradors $BODY = OptionsPeer::getString('BODY_MAIL_MISSATGE_GLOBAL', $this->getSiteId()); $BODY = str_replace('{NOM}', $this->getUsuaris()->getNomComplet(), $BODY); $BODY = str_replace('{SITE}', $this->getSiteNom(), $BODY); $BODY = str_replace('{ENLLAC}', 'http://www.casadecultura.cat/gestio/gMissatges?accio=E&IDM=' . $this->getMissatgeid(), $BODY); $SUBJECT = 'Hospici : Nou missatge global'; myUser::sendMail($ADMIN, $MAILS, $SUBJECT, $BODY); }
private function sendMail($from, $to, $subject, $body = "", $files = array()) { //Ho he passat a myUser per fer-ho més compatible amb totes les parts del programa. myUser::sendMail($from, $to, $subject, $body, $files); }