Changeset 17092
- Timestamp:
- 2008/02/28 12:00:48 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/version-2/data/class/SC_SendMail.php
r17086 r17092 64 64 65 65 // 送信先の設定 66 function setRecip($ recipient) {67 $this->arrRecip[ ] = $recipient;66 function setRecip($key, $recipient) { 67 $this->arrRecip[$key] = $recipient; 68 68 } 69 69 … … 72 72 if($to != "") { 73 73 $this->to = $this->getNameAddress($to_name, $to); 74 $this->setRecip( $to);74 $this->setRecip("To", $to); 75 75 } 76 76 } … … 85 85 if($cc != "") { 86 86 $this->cc = $this->getNameAddress($cc_name, $cc); 87 $this->setRecip( $cc);87 $this->setRecip("Cc", $cc); 88 88 } 89 89 } … … 93 93 if($bcc != "") { 94 94 $this->bcc = $bcc; 95 $this->setRecip( $bcc);95 $this->setRecip("Bcc", $bcc); 96 96 } 97 97 } … … 243 243 return $arrHeader; 244 244 } 245 246 // 送信先を返す 247 function getRecip() { 248 switch ($this->backend) { 249 case "mail": 250 return $this->to; 251 break; 252 case "sendmail": 253 case "smtp": 254 default: 255 return $this->arrRecip; 256 break; 257 } 258 } 245 259 246 260 // TXTメール送信を実行する … … 248 262 $header = $this->getTEXTHeader(); 249 263 // メール送信 250 $result = $this->objMail->send($this-> arrRecip, $header, $this->body);264 $result = $this->objMail->send($this->getRecip(), $header, $this->body); 251 265 if (PEAR::isError($result)) { 252 266 GC_Utils_Ex::gfPrintLog($result->getMessage()); … … 261 275 $header = $this->getHTMLHeader(); 262 276 // メール送信 263 $result = $this->objMail->send($this-> arrRecip, $header, $this->body);277 $result = $this->objMail->send($this->getRecip(), $header, $this->body); 264 278 if (PEAR::isError($result)) { 265 279 GC_Utils_Ex::gfPrintLog($result->getMessage()); … … 279 293 switch ($backend) { 280 294 case "mail": 281 295 $arrParams = array(); 282 296 break; 283 297 case "sendmail": … … 292 306 'port' => $this->port 293 307 ); 308 break; 294 309 } 295 310 return $arrParams;
Note: See TracChangeset
for help on using the changeset viewer.