Php Outlook 2013中收到的电子邮件CSV附件为空
我只在Outlook 2013中没有收到数据CSV附件电子邮件,但在gmail和其他邮件中收到了数据CSV。 我使用了以下CakePHP代码:Php Outlook 2013中收到的电子邮件CSV附件为空,php,email,cakephp,csv,outlook,Php,Email,Cakephp,Csv,Outlook,我只在Outlook 2013中没有收到数据CSV附件电子邮件,但在gmail和其他邮件中收到了数据CSV。 我使用了以下CakePHP代码: $this->Email->reset(); $fileatt = ROOT . DS . APP_DIR . DS . WEBROOT_DIR . DS; $this->Email->to =array('ram@xyz.com');
$this->Email->reset();
$fileatt = ROOT . DS . APP_DIR . DS . WEBROOT_DIR . DS;
$this->Email->to =array('ram@xyz.com');
$this->Email->cc =array('ram@gmail.com');
$this->Email->subject = "CSV mail";
$this->Email->from = "info@gmail.com";
$this->Email->sendAs = 'html';
$this->Email->filePaths = array($fileatt);
$this->Email->attachments =array("Sample.csv");
$this->Email->charset = "utf-8";
$this->Email->headerCharset = "utf-8";
$message = "Hi Thanks!";
$this->Email->send($message);
帮我解决这个问题
您应该在附件中使用此代码
这不起作用,我在其他邮件服务gmail、yahoo中收到了csv文件,但仍然收到outlook 2013的空csv文件。这个问题是否出现在2013年展望上?
$Email->attachments(array(
'Sample.csv' => array(
'file' => WWW_ROOT.'img/doc/Sample.csv',
'mimetype' => 'text/csv',
'contentId' => 'my-unique-id'
)
));