<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel>
  <title>aC forum: PHP email not working</title>
  <link>http://www.activecollab.com/forums/topic/1063/</link>
  <description>Recent posts on topic: PHP email not working</description>
  <dc:language>en-us</dc:language>
  <pubDate>Sat, 05 Jul 2008 08:53:08 CDT</pubDate>
  
  <item>
    <link>http://www.activecollab.com/forums/post/11602/#post11602</link>
    <guid>http://www.activecollab.com/forums/post/11602/#post11602</guid>
    <title>Post #19 by conway98</title>
    <dc:creator>conway98</dc:creator>
    <description><![CDATA[<p>I used a cheap hack to fix this problem on my installation.  The problem seems to be somewhere with the Swift library. I didn't bother to track it down, I just switched to the standard php mailer. I changed the sendEmail() function in Notifer.class.php line 220 (/application/models/notifier/Notifier.class.php) to this:<br />
<br />
static function sendEmail($to, $from, $subject, $body = false, $type = 'text/plain', $encoding = 'utf-8') {<br />
      return mail($to,$subject,$body,'From: activeCollab Mailer &lt;'.$from.&quot;&gt;\r\n&quot;);<br />
      //Env::useLibrary('swift');<br />
      <br />
      //$mailer = self::getMailer();<br />
      //if(!($mailer instanceof Swift)) {<br />
      //  throw new NotifierConnectionError();<br />
      //} // if<br />
      <br />
      //$result = $mailer-&gt;send($to, $from, $subject, $body, $type, $encoding);<br />
      //$mailer-&gt;close();<br />
      <br />
      //return $result;<br />
    } // sendEmail<br />
<br />
I commented everything out and added the line &quot;return mail($to,$subject,$body,'From: activeCollab Mailer &lt;'.$from.&quot;&gt;\r\n&quot;);&quot;.</p>]]></description>
    <pubDate>Wed, 30 Jan 2008 21:08:17 CST</pubDate>
  </item>
  <item>
    <link>http://www.activecollab.com/forums/post/10452/#post10452</link>
    <guid>http://www.activecollab.com/forums/post/10452/#post10452</guid>
    <title>Post #18 by WorldLightMedia</title>
    <dc:creator>WorldLightMedia</dc:creator>
    <description><![CDATA[<p>I had this same problem. It was working fine, then it stopped. Here's how I fixed mine: <br />
<br />
<br />
Go into the email configuration [  Dashboard  » Administration  » Configuration » Mailing]<br />
 and change the &quot;Mail transport&quot; setting to &quot;Default PHP settings&quot;.  I'm not sure why this works... but it does!<br />
</p>]]></description>
    <pubDate>Mon, 29 Oct 2007 22:55:53 CDT</pubDate>
  </item>
  <item>
    <link>http://www.activecollab.com/forums/post/8688/#post8688</link>
    <guid>http://www.activecollab.com/forums/post/8688/#post8688</guid>
    <title>Post #17 by uberjivy</title>
    <dc:creator>uberjivy</dc:creator>
    <description><![CDATA[<p>My default mail options were also not working.  As a crappy workaround, I bypassed the Swift mailer object for the native sendmail() approach:<br />
<br />
application/models/notifier/Notifier.class.php<br />
<br />
<pre name="code" class="php">    static function sendEmail($to, $from, $subject, $body = false, $type = 'text/plain', $encoding = '8bit') {
      Env::useLibrary('swift');
      
      $mailer = self::getMailer();
      if(!($mailer instanceof Swift)) {
        throw new NotifierConnectionError();
      } // if

      // Bypass fancy mailer if using sendmail
      $mail_transport_config = config_option('mail_transport', self::MAIL_TRANSPORT_MAIL);
      if($mail_transport_config == self::MAIL_TRANSPORT_MAIL) {
        $headers =
          &quot;From: $from\r\n&quot;.
          &quot;Content-Type: $type; charset=\&quot;{$mailer-&gt;charset}\&quot;; format=flowed\r\n&quot;.
          &quot;Content-Transfer-Encoding: $encoding\r\n&quot;;
        return mail($to, $subject, $body, $headers, &quot;-r $from&quot;);
      }

      $result = $mailer-&gt;send($to, $from, $subject, $body, $type, $encoding);
      $mailer-&gt;close();
      
      return $result;
    } // sendEmail</pre><br />
<br />
The extra &quot;-r $from&quot; was necessary for my host's sendmail install to get the From header working properly.  Your mileage may vary.</p>]]></description>
    <pubDate>Wed, 12 Sep 2007 00:09:17 CDT</pubDate>
  </item>
  <item>
    <link>http://www.activecollab.com/forums/post/7338/#post7338</link>
    <guid>http://www.activecollab.com/forums/post/7338/#post7338</guid>
    <title>Post #16 by funhyun</title>
    <dc:creator>funhyun</dc:creator>
    <description><![CDATA[<p>Nevermind, I will use my gmail account with the ac thanks to the thread http://www.activecollab.com/forums/topic/832/ .<br />
:)<br />
</p>]]></description>
    <pubDate>Wed, 28 Mar 2007 08:47:38 CDT</pubDate>
  </item>
  <item>
    <link>http://www.activecollab.com/forums/post/7312/#post7312</link>
    <guid>http://www.activecollab.com/forums/post/7312/#post7312</guid>
    <title>Post #15 by funhyun</title>
    <dc:creator>funhyun</dc:creator>
    <description><![CDATA[<p>Any ideas, anyone?</p>]]></description>
    <pubDate>Mon, 26 Mar 2007 08:30:13 CDT</pubDate>
  </item>
  <item>
    <link>http://www.activecollab.com/forums/post/7252/#post7252</link>
    <guid>http://www.activecollab.com/forums/post/7252/#post7252</guid>
    <title>Post #14 by funhyun</title>
    <dc:creator>funhyun</dc:creator>
    <description><![CDATA[<p>Getting back to the original question posted by Snailface, I am on VPS server on PHP 5.0.4 and when I send emails from &quot;Tool&quot; section or when a comments are posted, no one is getting an email notification. <br />
<br />
I am using the Default PHP Settings Method.<br />
<br />
Also, I get no error warnings. Any advice would be greatly appreciated! <br />
:) </p>]]></description>
    <pubDate>Thu, 22 Mar 2007 05:23:56 CDT</pubDate>
  </item>
  <item>
    <link>http://www.activecollab.com/forums/post/7218/#post7218</link>
    <guid>http://www.activecollab.com/forums/post/7218/#post7218</guid>
    <title>Post #13 by jrileybowker</title>
    <dc:creator>jrileybowker</dc:creator>
    <description><![CDATA[<p>Hi folks-<br />
<br />
I installed ActiveCollab on Windows XP, with McAffee virus protection software.  Unbeknownst to me, the virus software refused to let me make a connection to my smtp server. I had to uncheck the &quot;prevent mass mailing worms from sending mail&quot; setting to make it work. The tip-off was that I couldn't telnet to my smtp server; the telnet error said the connection was refused. <br />
<br />
Hope this is useful to future users.<br />
<br />
Regards,<br />
Janet<br />
<br />
</p>]]></description>
    <pubDate>Mon, 19 Mar 2007 14:21:25 CDT</pubDate>
  </item>
  <item>
    <link>http://www.activecollab.com/forums/post/7205/#post7205</link>
    <guid>http://www.activecollab.com/forums/post/7205/#post7205</guid>
    <title>Post #12 by Ilija Studen</title>
    <dc:creator>Ilija Studen</dc:creator>
    <description><![CDATA[<p>To work around this problem turn on Exchange Compatibility option in Mailing settings (Administration -&gt; Configuration).</p>]]></description>
    <pubDate>Sun, 18 Mar 2007 12:19:52 CDT</pubDate>
  </item>
  <item>
    <link>http://www.activecollab.com/forums/post/7204/#post7204</link>
    <guid>http://www.activecollab.com/forums/post/7204/#post7204</guid>
    <title>Post #11 by objecta</title>
    <dc:creator>objecta</dc:creator>
    <description><![CDATA[<p>Just to add to the previuos post. Found this thread regarding the problem.<br />
<br />
http://bugs.php.net/bug.php?id=28038<br />
<br />
Objecta</p>]]></description>
    <pubDate>Sun, 18 Mar 2007 12:10:44 CDT</pubDate>
  </item>
  <item>
    <link>http://www.activecollab.com/forums/post/7202/#post7202</link>
    <guid>http://www.activecollab.com/forums/post/7202/#post7202</guid>
    <title>Post #10 by objecta</title>
    <dc:creator>objecta</dc:creator>
    <description><![CDATA[<p>Hi<br />
<br />
I have the same problems and have studied the log file from my mail server and found the following entry:<br />
&quot;RECEIVED: RCPT TO:&lt;Michael &lt;webmaster@objecta.dk&gt;&gt;&quot;<br />
&quot;SENT: 550 Unknown user&quot;<br />
<br />
I get this error when I added a new user (Michael) and checked the &quot;Send email notification&quot;. Somehow the username added to the email adress is the coursing for this error.<br />
<br />
Objecta</p>]]></description>
    <pubDate>Sun, 18 Mar 2007 04:26:07 CDT</pubDate>
  </item>
</channel>
</rss>