我正在開發我的網站上的時事通訊模塊,我從Symfony 1.4版本開始。 我想發送我的電子郵件給多個收件人。Symfony 1.4中的時事通訊模塊
我想這個簡單的解決方案(與實時交付策略):
$message = $this->getMailer()->compose();
$message->setSubject('My subject');
$message->setTo(array('[email protected]', '[email protected]'));
$message->setFrom('[email protected]', 'Name of expeditor');
$html = $this->getPartial('module/action', array('var'=>$var));
$message->setBody($html, 'text/html');
$number = $this->getMailer()->send($message);
電子郵件的發送,但收件人列表中你可以看到所有用戶,而不僅僅是你...
此外,可能有很多收件人。所以也許我需要一個等待列表來避免最大執行時間錯誤?
如果可能的話,你可以幫助找到更好的解決方案嗎?
謝謝
謝謝你的幫助,它更好! – deodys 2010-11-23 15:26:14