I have the same problem and I did not manage to find many answer to
this question., it took me a while to solve the problem, to clarify,
I got it working by
$this->Email->filePaths = array('/home/username/');
$this->Email->attachments =array('article_button.png');
$this->Email->to = '[EMAIL PROTECTED]';
$this->Email->subject = 'Something';
$this->Email->replyTo = $client['Client']['email'];
$this->Email->from = $client['Client']['email'];
$this->Email->sendAs = 'html';
if($this->Emailer->send('Testing', null, null)){
die('Email Sent!');
}else{
die('Failed to send email');
}
www.genericsmed.com
www.generics.ws
On Apr 21, 9:47 pm, Doug <[EMAIL PROTECTED]> wrote:
> I've done a scount round the group for info on this but not found any
> help. One person wasn't answered - I hope that won't be the case this
> time round.
>
> Basically I'm attempting to send anemailwithattachment. Using this
> code:
> //@todo Send from clientemailaddress
> $this->Email->to = '[EMAIL PROTECTED]';
> $this->Email->subject = 'Something';
> $this->Email->replyTo = $client['Client']['email'];
> $this->Email->from = $client['Client']['email'];
> $this->Email->sendAs = 'html';
> $this->Email->attachments = array('/home/username/
> article_button.png');
> if($this->Emailer->send('Testing', null, null)){
> die('EmailSent!');
> }else{
> die('Failed to sendemail');
> }
>
> It dies with "EmailSent" and I do get theemailin my inbox. However
> there's noattachment. Anyone got any ideas? I've checked
> permissions on the file and chmodded them to 777. No luck there.
>
> Hoipe you can help.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---