7.03 Mass Mailer Problem

I am hoping someone can help me fix this error.  I have been trying to fix this for
almost two months. When I send out a mass email, I get a notice that says email was
sent successfully. But no members receive the emails and I get an a return email
stating I have an error. The message remains in the que.

I have looked at the BxDolNotifies.php file for line 44, but don't

know what needs to be fixed. Can anyone help, please!

Database error in CaboFriends.net<br /><br />

Query: <pre>SELECT `id`, `email`, `subject`, `body` FROM `sys_sbs_queue` ORDER
BY `id` LIMIT 0, 5m</pre> Mysql error: You have an error in your SQL syntax;
check the manual that corresponds to your MySQL server version for the right
syntax to use near '5m' at line 1<br /><br /> Found error in the file
'<b>/home/maddie/public_html/inc/classes/BxDolCronNotifies.php</b>' at line
<b>44</b>.<br />
Called '<b>getAll</b>' function with erroneous argument #<b>0</b>.<br /><br
/><br /> Debug backtrace:
<pre>Array
(
[1] =&gt; Array
(
[file] =&gt; /home/maddie/public_html/inc/classes/BxDolDb.php
[line] =&gt; 237
[function] =&gt; error
[class] =&gt; BxDolDb
[type] =&gt; -&gt;
[object] =&gt; BxDolDb Object
(
[error_checking] =&gt; 1
[host] =&gt; localhost
[port] =&gt;
[socket] =&gt;
[dbname] =&gt; maddie_dolph53
[user] =&gt; *****
[password] =&gt; *****
[link] =&gt; Resource id #33
[current_res] =&gt;
[current_arr_type] =&gt; 1
[oParams] =&gt; BxDolParams Object
(
[_oDb] =&gt; BxDolDb Object
*RECURSION*
[_oCache] =&gt; BxDolCacheFile Object
(
[sPath] =&gt; /home/maddie/public_html/cache/
[_error] =&gt;
)

[_sCacheFile] =&gt; sys_options_2aca8b14dbd9855210aa80306ab28a53.php
[_aParams] =&gt; Array
Quote · 30 Nov 2010

have you updated to 7.0.3 or is it the new installation,

post your file inc/classes/BxDolCronNotifies.php here

Quote · 30 Nov 2010

 

have you updated to 7.0.3 or is it the new installation,

post your file inc/classes/BxDolCronNotifies.php here

This is a new install ... 7.03     It's been up and running since October 2nd or 3rd.  Here is a copy of my file.  Thanks.

Dolphin Smart Community Builder
*                              -------------------
*     begin                : Mon Mar 23 2006
*     copyright            : (C) 2007 BoonEx Group
*     website              : http://www.boonex.com
* This file is part of Dolphin - Smart Community Builder
*
* Dolphin is free software; you can redistribute it and/or modify it under
* the terms of the GNU General Public License as published by the
* Free Software Foundation; either version 2 of the
* License, or  any later version.
*
* Dolphin is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
* without even the implied warranty of  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
* See the GNU General Public License for more details.
* You should have received a copy of the GNU General Public License along with Dolphin,
* see license.txt file; if not, write to marketing@boonex.com
***************************************************************************/

require_once( BX_DIRECTORY_PATH_INC . 'db.inc.php' );
require_once('BxDolCron.php');

class BxDolCronNotifies extends BxDolCron {

function processing() {
global $site;

set_time_limit( 36000 );
ignore_user_abort();

$sResult = "";        
$iPerStart = getParam('msgs_per_start');

$iFullCount = (int)$GLOBALS['MySQL']->getOne('SELECT COUNT(*) FROM `sys_sbs_queue`');
if($iFullCount) {
$iProcess = $iFullCount < $iPerStart ? $iFullCount : $iPerStart;

$sResult .= "\n- Start email send -\n";
$sResult .= "Total queued emails: " . $iFullCount . "\n";
$sResult .= "Ready for send: " . $iProcess . "\n";

$aMails = $GLOBALS['MySQL']->getAll("SELECT `id`, `email`, `subject`, `body` FROM `sys_sbs_queue` ORDER BY `id` LIMIT 0, " . $iProcess);

$iSent = 0;
$aIds = array();            
foreach($aMails as $aMail) {
$aIds[] = $aMail['id'];
if(sendMail($aMail['email'], $aMail['subject'], $aMail['body']))
$iSent++;
else
$sResult .= "Cannot send message to " . $aMail['email'] . "\n";
}            
$GLOBALS['MySQL']->query("DELETE FROM `sys_sbs_queue` WHERE `id` IN ('" . implode("','", $aIds) . "')");

$sResult .= "Processed emails: " . $iSent . "\n";
sendMail($site['email'], $site['title'] . ": Periodic Report", $sResult);

periodic_check_ban();
}
}
}

?>

Quote · 30 Nov 2010

I hope you missed some of the copy/paste since the opening ?> is missing from the top of the file.

 

Have you tried re-uploading a fresh version of BxDolCronNotifies.php from the 7.0.3 download package and clear your /cache (except the .htaccess file) and /cache_public directories?

 

Nothing to see here
Quote · 1 Dec 2010

 

I hope you missed some of the copy/paste since the opening ?> is missing from the top of the file.

 

Have you tried re-uploading a fresh version of BxDolCronNotifies.php from the 7.0.3 download package and clear your /cache (except the .htaccess file) and /cache_public directories?

 

No, I didn't miss any of the copy and paste.  What is it that I am missing?  Is there a copy of the file somewhere to look at and compare?  I will try uploading a fresh installation of BxDolCronNotifies.php ... where can I find a download for 7.03?  I only see the 7.04 available on the site?

 

Also, can anyone tell what the erroneous error is and what the correct "syntax" should be?

Found error in the file 
'<b>/home/maddie/public_html/inc/classes/BxDolCronNotifies.php</b>' at line
<b>44</b>.<br />
Called '<b>getAll</b>' function with erroneous argument #<b>0</b>.<br /><br
/><br /> Debug backtrace:
<pre>Array


Here is line 44

 $aMails = $GLOBALS['MySQL']->getAll("SELECT `id`, `email`,
`subject`, `body` FROM `sys_sbs_queue` ORDER BY `id` LIMIT 0, " .
$iProcess);
Quote · 1 Dec 2010

You should have one in the 7.0.3 package that you downloaded. But just in case you can't seem to find that, I have attached a 7.0.3 version of BxDolCronNotifies.php for you.

BxDolCronNotifies.php · 2.7K · 71 downloads
Nothing to see here
Quote · 1 Dec 2010

 

You should have one in the 7.0.3 package that you downloaded. But just in case you can't seem to find that, I have attached a 7.0.3 version of BxDolCronNotifies.php for you.

I re-uploaded the file and nothing changed.  I tried sending out another "mass mail" ... it states successful, but no mails are received by members.  I then get this error report emailed to me.

 

Database error in CaboFriends.net

Query:

SELECT `id`, `email`, `subject`, `body` FROM `sys_sbs_queue` ORDER BY `id` LIMIT 0, 5m

Mysql error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '5m' at line 1

Found error in the file '/home/maddie/public_html/inc/classes/BxDolCronNotifies.php' at line 44.
Called 'getAll' function with erroneous argument #0.


Debug backtrace:

 

Can anyone tell me what the error is?  What is erroneous? ... is it the #0 ?  If so,what should be there instead of the zero?

Quote · 1 Dec 2010

Please enter integer number in the following setting option:

Send emails from queue, it happens every cron execution (5m-1h)

You've entered "5m" and it cause the problems, enter something like "20"

Rules → http://www.boonex.com/terms
Quote · 2 Dec 2010

 

Please enter integer number in the following setting option:

Send emails from queue, it happens every cron execution (5m-1h)

You've entered "5m" and it cause the problems, enter something like "20"

I will do that,  thank you.

Quote · 2 Dec 2010

 

 

Please enter integer number in the following setting option:

Send emails from queue, it happens every cron execution (5m-1h)

You've entered "5m" and it cause the problems, enter something like "20"

I will do that,  thank you.

I just changed this from "5m" to "5"  and tried sending another "mass mail" and have not recieved any error messages so far.  I'd like to think it was that easy.  Now I did receive the following email message:

- Start email send - Total queued emails: 73 Ready for send: 5 Processed emails: 5

When I initially entered "5m" into where it says "Send emails from queue, it happens every cron execution (5m-1h) ... I thought I was supposed to enter how often I wanted the cron to run.  Since I have changed it to "5", and am receiving email reports stating 5 emails were sent ... am I safe to assume that the number I enter is actually how many emails I want sent out?  So if I have 73 members and I want one email to go to each of these members all at the same time ... I should enter the number 73?  Or is there something I can enter to show I want all members to be sent the email?

I can't believe how "stupid" I feel right now  ... I've been trying to get my mass mailer to work for almost two months and all along ... this was the problem.  I am continuing to get periodic messages that state 5 more emails were sent out.

Thank you so much, AlexT!

 

 

Quote · 2 Dec 2010

 

 

 

Please enter integer number in the following setting option:

Send emails from queue, it happens every cron execution (5m-1h)

You've entered "5m" and it cause the problems, enter something like "20"

I will do that,  thank you.

I just changed this from "5m" to "5"  and tried sending another "mass mail" and have not recieved any error messages so far.  I'd like to think it was that easy.  Now I did receive the following email message:

- Start email send - Total queued emails: 73 Ready for send: 5 Processed emails: 5

When I initially entered "5m" into where it says "Send emails from queue, it happens every cron execution (5m-1h) ... I thought I was supposed to enter how often I wanted the cron to run.  Since I have changed it to "5", and am receiving email reports stating 5 emails were sent ... am I safe to assume that the number I enter is actually how many emails I want sent out?  So if I have 73 members and I want one email to go to each of these members all at the same time ... I should enter the number 73?  Or is there something I can enter to show I want all members to be sent the email?

I can't believe how "stupid" I feel right now  ... I've been trying to get my mass mailer to work for almost two months and all along ... this was the problem.  I am continuing to get periodic messages that state 5 more emails were sent out.

Thank you so much, AlexT!

 

 

The name of setting option is not obvious - maybe we need to rename it.

This setting is number of emails to send each time, it happens every 10 minutes by default. I suggest to set it to default value - 20

Rules → http://www.boonex.com/terms
Quote · 3 Dec 2010

Oh my... I can NOT believe that I had the exact same problem and just had the exact same error!

 

I had 10m instead of only 10. :P

 

Thank you! :D

Quote · 17 Feb 2011
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.