From 748a6f7f53f7999cf3f3eee777d970f5beb7c951 Mon Sep 17 00:00:00 2001 From: wlx Date: Wed, 12 Oct 2011 13:33:32 +0000 Subject: [PATCH] add return in mailer --- application/models/WestdcMailer.php | 2 +- application/models/emailtext.php | 53 ----------------------------- 2 files changed, 1 insertion(+), 54 deletions(-) delete mode 100644 application/models/emailtext.php diff --git a/application/models/WestdcMailer.php b/application/models/WestdcMailer.php index f1e53d7a..cb30e3f2 100644 --- a/application/models/WestdcMailer.php +++ b/application/models/WestdcMailer.php @@ -11,6 +11,6 @@ class WestdcMailer extends Zend_Mail { } function send() { - parent::send($this->tr); + return parent::send($this->tr); } } \ No newline at end of file diff --git a/application/models/emailtext.php b/application/models/emailtext.php deleted file mode 100644 index 0366f1fd..00000000 --- a/application/models/emailtext.php +++ /dev/null @@ -1,53 +0,0 @@ -tmpid)||empty($this->tmpid)) - { - $this->tmpid = 0; - } - } - - public function loadtmp(){ - - if(empty($this->tmpid)) - { - return false; - }else{ - $sql = "select id,content from emailtext where id='".$this->tmpid."'"; - $rs = $this->db->query($sql); - - $c = $rs->fetch(); - if(!empty($c['id'])) - { - if(count($this->data)==0) - { - return false; - } - else - { - $patterns = array(); - $replacements = array(); - foreach($this->data as $k=>$v) - { - $patterns[]='/{'.$k.'}/i'; - $replacements[]=$v; - } - ksort($patterns); - ksort($replacements); - $newString=preg_replace($patterns, $replacements, $c['content']); - return $newString; - }//count($this->data) - } - else - { - return false; - } - }//empty($this->tmpid) - }//function loadtmp -} \ No newline at end of file