Changeset 17590 for branches/comu-ver2/data/class/helper/SC_Helper_Mail.php
- Timestamp:
- 2008/09/02 16:17:59 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/comu-ver2/data/class/helper/SC_Helper_Mail.php
r17375 r17590 69 69 if ($reply_to == "") $reply_to = $arrInfo['email03']; 70 70 $error = $arrInfo['email04']; 71 $tosubject = $tmp_subject; 71 $tosubject = $this->sfMakeSubject($tmp_subject); 72 72 73 $objSendMail->setItem('', $tosubject, $body, $from_address, $from_name, $reply_to, $error, $error); 73 74 $objSendMail->setTo($to, $to_name); … … 145 146 $from = $arrInfo['email03']; 146 147 $error = $arrInfo['email04']; 147 148 $tosubject = $this->sfMakeSubject($objQuery, $objMailView, 149 $objPage, $tmp_subject); 148 $tosubject = $this->sfMakeSubject($tmp_subject); 150 149 151 150 $objSendMail->setItem('', $tosubject, $body, $from, $arrInfo['shop_name'], $from, $error, $error, $bcc); … … 164 163 165 164 // テンプレートを使用したメールの送信 166 function sfSendTplMail($to, $ subject, $tplpath, &$objPage) {165 function sfSendTplMail($to, $tmp_subject, $tplpath, &$objPage) { 167 166 $objMailView = new SC_SiteView(); 168 167 $objSiteInfo = new SC_SiteInfo(); … … 179 178 $from = $arrInfo['email03']; 180 179 $error = $arrInfo['email04']; 181 $objSendMail->setItem($to, $subject, $body, $from, $arrInfo['shop_name'], $from, $error, $error, $bcc); 180 $tosubject = $this->sfMakeSubject($tmp_subject); 181 182 $objSendMail->setItem($to, $tosubject, $body, $from, $arrInfo['shop_name'], $from, $error, $error, $bcc); 182 183 $objSendMail->sendMail(); 183 184 } 184 185 185 186 // 通常のメール送信 186 function sfSendMail($to, $ subject, $body) {187 function sfSendMail($to, $tmp_subject, $body) { 187 188 $objSiteInfo = new SC_SiteInfo(); 188 189 $arrInfo = $objSiteInfo->data; … … 192 193 $from = $arrInfo['email03']; 193 194 $error = $arrInfo['email04']; 194 $objSendMail->setItem($to, $subject, $body, $from, $arrInfo['shop_name'], $from, $error, $error, $bcc); 195 $tosubject = $this->sfMakeSubject($tmp_subject); 196 197 $objSendMail->setItem($to, $tosubject, $body, $from, $arrInfo['shop_name'], $from, $error, $error, $bcc); 195 198 $objSendMail->sendMail(); 196 199 } 197 200 198 201 //件名にテンプレートを用いる 199 function sfMakeSubject(&$objQuery, &$objMailView, &$objPage, $subject){ 200 202 function sfMakeSubject($subject) { 203 $objQuery = new SC_Query(); 204 $objMailView = new SC_SiteView(); 205 $objTplAssign = new stdClass; 206 201 207 $arrInfo = $objQuery->select("*","dtb_baseinfo"); 202 208 $arrInfo = $arrInfo[0]; 203 $obj Page->tpl_shopname=$arrInfo['shop_name'];204 $obj Page->tpl_infoemail=$subject;205 $obj MailView->assignobj($objPage);206 $ mailtitle = $objMailView->fetch('mail_templates/mail_title.tpl');207 $ ret = $mailtitle.$subject;208 return $ ret;209 $objTplAssign->tpl_shopname=$arrInfo['shop_name']; 210 $objTplAssign->tpl_infoemail=$subject; // 従来互換 211 $objTplAssign->tpl_mailtitle=$subject; 212 $objMailView->assignobj($objTplAssign); 213 $subject = $objMailView->fetch('mail_templates/mail_title.tpl'); 214 return $subject; 209 215 } 210 216
Note: See TracChangeset
for help on using the changeset viewer.