Re: CakePHP email component problem

2011-09-11 Thread WebbedIT
duplicate thread: 
http://groups.google.com/group/cake-php/browse_thread/thread/13a87371c17428e
euromark has started supporting this at other thread

On Sep 10, 2:47 pm, Piotr Chabros  wrote:
> Hello,
>
> in my application there is a part of a code responsible of sending an
> emails to my users. It is a loop cycling through the whole database of
> users and just sending the email. Also when any email is sent, there
> is a copy sent to another email addres. The problem is that some of
> the users recieve other content in their email than it is in the copy.
>
> The commands are one under another, so I have no idea why this is
> happening:
>
> if ($TestMode == 'live') {   // if not in test mode
>                $this->Email->to = $User['User']['username']; //
> username - user's email address
>                $this->Email->bcc = array(c...@here.co.uk'); // mail to
> send a bcc copy
>             }else{ // if in test mode
>                $this->Email->to = array('sysadm...@hotmail.co.uk',
>                                     'sysadm...@gmail.com',
>                                     'sysadm...@googlemail.com');
>             }
>          // Send e-mail to user.
>                $this->Email->subject = 'blahblah;
>                $this->Email->template = 'my_template';
>                $this->Email->sendAs = 'html';
>                $this->Email->send();
>                $this->Email->reset();
>
> The above code is a part of the loop. But the question is, why some
> users are getting another email than it is sent to
> c...@here.hotmail.co.uk ? Maybe this problem is of another matter?
> Please help!

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php


Re: CAKEPHP Email component not working in live server.. how to get the error response why that mail is not going

2011-08-29 Thread John Hardy
Can you send an email VIA command line (sendmail or postfix)?


On Aug 29, 2011, at 4:42 AM, Gmail Support wrote:

> Hi 
> 
>   Thanx for your response. But my controller has 4 mail functions but none of 
> the mails are going in Live server only. Still I try to find a solution.
> 
> When a third party guys hitting our url we are sending mail to users. This is 
> working in my local. But i not used auth component or any authentication in 
> this controller.
> So I thinking that problem regarding that only. So I Plan to copy and move 
> the email contents to another controller, at the same time i will follow your 
> things 
> 
> 
> 
> On Tue, Aug 23, 2011 at 12:13 PM, ShadowCross  wrote:
> If using the EmailComponent works in other parts of your controller,
> and the "code excerpt" you provided was just manually entered into
> your original email (the first two lines would have resulted in a
> syntax error as it is written) you can try adding
> 
>  $this->Email->return = "Mysitename ";
> 
> before the call to $this->Email->send().  This will add the
> appropriate mail header to indicate what email address to send
> bounceback emails.  I've had some domains (such as gmail.com) refuse
> emails from my webserver because its a shared host that was at one
> time flagged as a potential spam source.  The bounceback emails are
> normally sent to the FROM address, but it looks like the FROM you are
> using is something like 'no-re...@mysite.com', which probably doesn't
> exist, so any delivery errors (remote mailserver down, remote user has
> exceeded his quota, unknown user, etc.) are being delivered into the
> ether.
> 
> It may also be possible that the receiving email client is routing
> your email to a spam folder. In this case, there will be no bounceback
> email. You could display a message like "The email has been sent to
> . Please make sure that  is on
> your list of trusted senders to avoid the mail being sent to your Spam
> folder.".  Of course, this will only work if the email is being sent
> as a direct result of the user interacting with your website.
> 
> Note: The fact that $this->Email->send() returns true doesn't mean the
> email was delivered; usually, it will use the PHP mail() function, and
> according to the PHP manual (http://php.net/manual/en/
> function.mail.php):
> 
>  Returns TRUE if the mail was successfully accepted for delivery,
> FALSE otherwise.
>  It is important to note that just because the mail was accepted for
> delivery, it does NOT mean the mail will actually reach the intended
> destination
> 
> BTW: Is there a reason you are wrapping the $this->Email->send()
> within ob_start()/ob_end_clean() ? Output buffering generally only
> deals with output that is being sent to the client browser, but $this-
> >Email->send() and $this->log() shouldn't be sending anything to the
> browser (unless you have Debug > 0, in which case you WANT to see the
> debug messages).
> 
> --
> Our newest site for the community: CakePHP Video Tutorials 
> http://tv.cakephp.org
> Check out the new CakePHP Questions site http://ask.cakephp.org and help 
> others with their CakePHP related questions.
> 
> 
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
> http://groups.google.com/group/cake-php
> 
> 
> -- 
> Our newest site for the community: CakePHP Video Tutorials 
> http://tv.cakephp.org 
> Check out the new CakePHP Questions site http://ask.cakephp.org and help 
> others with their CakePHP related questions.
>  
>  
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
> http://groups.google.com/group/cake-php

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php


Re: CAKEPHP Email component not working in live server.. how to get the error response why that mail is not going

2011-08-29 Thread Gmail Support
Hi

  Thanx for your response. But my controller has 4 mail functions but none
of the mails are going in Live server only. Still I try to find a solution.

When a third party guys hitting our url we are sending mail to users. This
is working in my local. But i not used auth component or any authentication
in this controller.
So I thinking that problem regarding that only. So I Plan to copy and move
the email contents to another controller, at the same time i will follow
your things



On Tue, Aug 23, 2011 at 12:13 PM, ShadowCross  wrote:

> If using the EmailComponent works in other parts of your controller,
> and the "code excerpt" you provided was just manually entered into
> your original email (the first two lines would have resulted in a
> syntax error as it is written) you can try adding
>
>  $this->Email->return = "Mysitename ";
>
> before the call to $this->Email->send().  This will add the
> appropriate mail header to indicate what email address to send
> bounceback emails.  I've had some domains (such as gmail.com) refuse
> emails from my webserver because its a shared host that was at one
> time flagged as a potential spam source.  The bounceback emails are
> normally sent to the FROM address, but it looks like the FROM you are
> using is something like 'no-re...@mysite.com', which probably doesn't
> exist, so any delivery errors (remote mailserver down, remote user has
> exceeded his quota, unknown user, etc.) are being delivered into the
> ether.
>
> It may also be possible that the receiving email client is routing
> your email to a spam folder. In this case, there will be no bounceback
> email. You could display a message like "The email has been sent to
> . Please make sure that  is on
> your list of trusted senders to avoid the mail being sent to your Spam
> folder.".  Of course, this will only work if the email is being sent
> as a direct result of the user interacting with your website.
>
> Note: The fact that $this->Email->send() returns true doesn't mean the
> email was delivered; usually, it will use the PHP mail() function, and
> according to the PHP manual (http://php.net/manual/en/
> function.mail.php):
>
>  Returns TRUE if the mail was successfully accepted for delivery,
> FALSE otherwise.
>  It is important to note that just because the mail was accepted for
> delivery, it does NOT mean the mail will actually reach the intended
> destination
>
> BTW: Is there a reason you are wrapping the $this->Email->send()
> within ob_start()/ob_end_clean() ? Output buffering generally only
> deals with output that is being sent to the client browser, but $this-
> >Email->send() and $this->log() shouldn't be sending anything to the
> browser (unless you have Debug > 0, in which case you WANT to see the
> debug messages).
>
> --
> Our newest site for the community: CakePHP Video Tutorials
> http://tv.cakephp.org
> Check out the new CakePHP Questions site http://ask.cakephp.org and help
> others with their CakePHP related questions.
>
>
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com For more options, visit this group
> at http://groups.google.com/group/cake-php
>

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php


Re: CAKEPHP Email component not working in live server.. how to get the error response why that mail is not going

2011-08-22 Thread ShadowCross
If using the EmailComponent works in other parts of your controller,
and the "code excerpt" you provided was just manually entered into
your original email (the first two lines would have resulted in a
syntax error as it is written) you can try adding

  $this->Email->return = "Mysitename ";

before the call to $this->Email->send().  This will add the
appropriate mail header to indicate what email address to send
bounceback emails.  I've had some domains (such as gmail.com) refuse
emails from my webserver because its a shared host that was at one
time flagged as a potential spam source.  The bounceback emails are
normally sent to the FROM address, but it looks like the FROM you are
using is something like 'no-re...@mysite.com', which probably doesn't
exist, so any delivery errors (remote mailserver down, remote user has
exceeded his quota, unknown user, etc.) are being delivered into the
ether.

It may also be possible that the receiving email client is routing
your email to a spam folder. In this case, there will be no bounceback
email. You could display a message like "The email has been sent to
. Please make sure that  is on
your list of trusted senders to avoid the mail being sent to your Spam
folder.".  Of course, this will only work if the email is being sent
as a direct result of the user interacting with your website.

Note: The fact that $this->Email->send() returns true doesn't mean the
email was delivered; usually, it will use the PHP mail() function, and
according to the PHP manual (http://php.net/manual/en/
function.mail.php):

  Returns TRUE if the mail was successfully accepted for delivery,
FALSE otherwise.
  It is important to note that just because the mail was accepted for
delivery, it does NOT mean the mail will actually reach the intended
destination

BTW: Is there a reason you are wrapping the $this->Email->send()
within ob_start()/ob_end_clean() ? Output buffering generally only
deals with output that is being sent to the client browser, but $this-
>Email->send() and $this->log() shouldn't be sending anything to the
browser (unless you have Debug > 0, in which case you WANT to see the
debug messages).

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php


Re: CAKEPHP Email component not working in live server.. how to get the error response why that mail is not going

2011-08-22 Thread Gmail Support
no dude... other mail functions from this controller are working fine

On Mon, Aug 22, 2011 at 2:05 PM, abhimanyu bv  wrote:

> maybe you have forgot to configure smtp settings in your cakephp.
>
> --
> Our newest site for the community: CakePHP Video Tutorials
> http://tv.cakephp.org
> Check out the new CakePHP Questions site http://ask.cakephp.org and help
> others with their CakePHP related questions.
>
>
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com For more options, visit this group
> at http://groups.google.com/group/cake-php
>

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php


Re: CAKEPHP Email component not working in live server.. how to get the error response why that mail is not going

2011-08-22 Thread abhimanyu bv
maybe you have forgot to configure smtp settings in your cakephp.

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php


Re: cakephp email component

2010-07-19 Thread Jeremy Burns | Class Outfit
It is so hard to help you with questions like this when we don't know what's 
going wrong. Can you be more specific? Can you paste an error message?

Jeremy Burns
Class Outfit

jeremybu...@classoutfit.com
http://www.classoutfit.com

On 19 Jul 2010, at 08:12, fadhli - wrote:

>  class MessagesController extends AppController {
> 
>   var $name = 'Messages';
> var $components = array('Email');
> 
> function _sendNewMessage($id) {
> $message = $this->Message->read(null,$id);
> 
> $this->Email->to = $message['Client']['email'];
> $this->Email->bcc = array('fad...@c-artsmag.com');
> $this->Email->subject = 'Welcome to our really cool thing';
> 
> $this->Email->replyTo = 'supp...@example.com';
> $this->Email->from = 'Cool Web App ';
> 
> $this->Email->template = 'simple_message'; // note no '.ctp'
> //Send as 'html', 'text' or 'both' (default is 'text')
> $this->Email->sendAs = 'both'; // because we like to send 
> pretty mail
> 
> //Set view variables as normal
> $this->set('message', $message);
> //Do not pass any args to send()
> $this->Email->send();
> }
> 
> 
>   ...
> ...
> ...
> 
>   function add() {
>   if (!empty($this->data)) {
>   $this->Message->create();
>   if ($this->Message->save($this->data)) {
> $this->_sendNewMessage( $this->Message->id );
> 
>   $this->Session->setFlash(sprintf(__('The %s has 
> been saved', true), 'message'));
>   $this->redirect(array('action' => 'index'));
>   } else {
>   $this->Session->setFlash(sprintf(__('The %s 
> could not be saved. Please, try again.', true), 'message'));
> 
>   }
>   }
>   $users = $this->Message->User->find('list', 
> array('fields'=>array('User.id', 'User.username')));
>   $clients = $this->Message->Client->find('list');
> 
>   $this->set(compact('users', 'clients'));
>   }
> ...
> ...
> ...
> }
> 
> ?>
> 
> 
> 
> 
> I use the cakephp 1.3.0 and yahoo web hosting.
> i write the code above to send email, but it does not work properly. anyone 
> can help me so this method works well.
> 
> Check out the new CakePHP Questions site http://cakeqs.org and help others 
> with their CakePHP related questions.
>  
> You received this message because you are subscribed to the Google Groups 
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
> http://groups.google.com/group/cake-php?hl=en

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


Re: cakephp email component

2008-09-22 Thread base64
ok thanks all, finnaly i am using phpmailer to send email.

On Mon, Sep 22, 2008 at 7:23 AM, RichardAtHome <[EMAIL PROTECTED]>wrote:

>
> I suspect you are trying to SMTP to gmail or something similar.
>
> CakePHP doesn't support the encyption required to connect to these
> types of SMTP server.
>
> The Bakery has some useful articles for using 3rd party mail
> components that support encrypted SMTP
>
> On Sep 22, 10:35 am, Predominant <[EMAIL PROTECTED]> wrote:
> > Hey base64,
> >
> > This message "220-We do not authorize .." is being produced by one of
> > the mail servers charged with delivering your mail message.
> > Try using a mail server you have authority to use.
> >
> > Cheers,
> > Predom.
> >
> > On Sep 22, 3:32 am, base64 <[EMAIL PROTECTED]> wrote:
> >
> > > Dear all,
> >
> > > I'm using CakePHP Email component,  when i sent email and i set
> smtp_errors;
> >
> > > $this->set('smtp-errors', $this->Email->smtpError);
> >
> > > the variable *smtp-errors* return : *220-We do not authorize the use of
> this
> > > system to transport unsolicited, *and my email did'not sent.*
> >
> > > *how to solved this problem?, and what can I do to send email using
> CakePHP
> > > email component?. I had follow this instruction step by step : *
> http://book.cakephp.org/view/176/Email*
> >
> > > Thanks
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
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
-~--~~~~--~~--~--~---



Re: cakephp email component

2008-09-22 Thread RichardAtHome

I suspect you are trying to SMTP to gmail or something similar.

CakePHP doesn't support the encyption required to connect to these
types of SMTP server.

The Bakery has some useful articles for using 3rd party mail
components that support encrypted SMTP

On Sep 22, 10:35 am, Predominant <[EMAIL PROTECTED]> wrote:
> Hey base64,
>
> This message "220-We do not authorize .." is being produced by one of
> the mail servers charged with delivering your mail message.
> Try using a mail server you have authority to use.
>
> Cheers,
> Predom.
>
> On Sep 22, 3:32 am, base64 <[EMAIL PROTECTED]> wrote:
>
> > Dear all,
>
> > I'm using CakePHP Email component,  when i sent email and i set smtp_errors;
>
> > $this->set('smtp-errors', $this->Email->smtpError);
>
> > the variable *smtp-errors* return : *220-We do not authorize the use of this
> > system to transport unsolicited, *and my email did'not sent.*
>
> > *how to solved this problem?, and what can I do to send email using CakePHP
> > email component?. I had follow this instruction step by step : 
> > *http://book.cakephp.org/view/176/Email*
>
> > Thanks
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
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
-~--~~~~--~~--~--~---



Re: cakephp email component

2008-09-22 Thread Predominant

Hey base64,

This message "220-We do not authorize .." is being produced by one of
the mail servers charged with delivering your mail message.
Try using a mail server you have authority to use.

Cheers,
Predom.



On Sep 22, 3:32 am, base64 <[EMAIL PROTECTED]> wrote:
> Dear all,
>
> I'm using CakePHP Email component,  when i sent email and i set smtp_errors;
>
> $this->set('smtp-errors', $this->Email->smtpError);
>
> the variable *smtp-errors* return : *220-We do not authorize the use of this
> system to transport unsolicited, *and my email did'not sent.*
>
> *how to solved this problem?, and what can I do to send email using CakePHP
> email component?. I had follow this instruction step by step : 
> *http://book.cakephp.org/view/176/Email*
>
> Thanks
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
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
-~--~~~~--~~--~--~---