Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
Hi,
When trying to send a newsletter with manual send rate, the emails are not being sent. These are the steps I followed:
1. Create a template.
2. Create a list using that template with 'Manual' send rate.
3. Add subscribers (Mass) to that list.
4. Click 'send' under the 'Operations' column of the 'Create/Send' tab.
5. Run cron.
6. Under the 'Statistics' tab, it shows a timestamp for 'Last sent' but the value of 'Emails sent' is 0.
Note that when I 'create and send a custom newsletter', the emails are sent correctly to subscribers of the list. Thanks for investigating!
Comments
Comment #1
ParisLiakos CreditAttribution: ParisLiakos commentedCheck reports->recent log entries.
Any messages after you run cron and click send on the manual list concerning this list?
Comment #2
jstruong CreditAttribution: jstruong commentedOur developers have set up syslog to show errors only. There were no errors logged after clicking send and then running cron.
Comment #3
ParisLiakos CreditAttribution: ParisLiakos commentedunfortunately newsletter messages are not errors:/ so you will have to enable dblog for a minute, try to send a newsletter and check it if you want to know whats really happening
Comment #4
ParisLiakos CreditAttribution: ParisLiakos commentedComment #5
darksniperx CreditAttribution: darksniperx commentedThis is similar issue to http://drupal.org/node/1394346 and http://drupal.org/node/1419004
And the error code is : 1 Newsletter Lists failed to send because no published nodes found for their terms
I have exact same issue, and i have tried everything. With tags set to none in template, then creating and publishing content with some tags, still nothing.
I wish there was a bypass for tags in manual sending.
Technically when tags is set to none, the newsletter is still trying to get the tags list, and fails anyways.
And I cannot run the patch file in the first link, post a build with implemented bypass what would be perfect.
Comment #6
mvahlsing CreditAttribution: mvahlsing commentedI follow the same steps as initial posting but get the list of errors - big long list of them.
Notice: Undefined variable: result in NewsletterCustom->send() (line 88 of /home/username/public_html/sites/all/modules/newsletter/includes/newsletter.custom.inc).
running the latest releases as updated by drush.
Sending newsletter at a manual rate, then run cron.
Comment #7
moonshdw8 CreditAttribution: moonshdw8 commentedJoining thread since I'm having the same issue. I wish I had more to add but can't seem to make any headway myself.
Comment #8
Patricia_W CreditAttribution: Patricia_W commentedPerhaps this is the problem.
I applied a patch to the newsletter module to add the variable to send if no published nodes. There were patches to 4 files.
Unfortunately I applied the patch manually and did not record the actual patch number, and am not that sure I have included the full patch code. Perhaps you can find the patch, I don't have the right time now.
patch code
for newsletter.admin.inc
$form['always_send'] = array(
'#type' => 'checkbox',
'#default_value' => FALSE,
'#title' => t('Send newsletter even if there are no nodes to list.'),
);
for newsletter.module
'newsletter_list' => array(
'label' => t('Newsletter list'),
'controller class' => 'NewsletterListController',
'base table' => 'newsletter_list',
'fieldable' => TRUE,
'entity keys' => array(
'id' => 'nlid',
'label' => 'title',
),
'bundles' => array(
'newsletter_list' => array(
'label' => t('Newsletter list'),
'admin' => array( /*PATCHED by PAW 9/10/2012 insert 3 lines*/
'path' => 'admin/config/media/newsletter/lists',
'access arguments' => array('administer newsletters'),
),
for newsletter.install
/* patched by PAW 9/10/2012 */
'always_send' => array(
'description' => 'Whether or not the newsletter should be sent regardless of new nodes present.',
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0,
), /* end of patch */
for newsletter.automated.inc
// patched by PAW 9/10/2012 */
if (empty($nodes) && !$this->list->always_send) {
continue;
}
Comment #9
chetanvsquare CreditAttribution: chetanvsquare commentedWhen i run the cron getting the error regarding newsletter module and not able to figure it out
Notice: Undefined index: 37 in newsletter_newsletter_load() (line 1038 of /home/v2dl/www/marketing/sites/all/modules/newsletter/newsletter.module).
Notice: Trying to get property of non-object in newsletter_add_open_rate_image() (line 1142 of /home/v2dl/www/marketing/sites/all/modules/newsletter/newsletter.module).
Notice: Undefined variable: hash in newsletter_add_open_rate_image() (line 1145 of /home/v2dl/www/marketing/sites/all/modules/newsletter/newsletter.module).
Notice: Trying to get property of non-object in newsletter_add_open_rate_image() (line 1142 of /home/v2dl/www/marketing/sites/all/modules/newsletter/newsletter.module).
Notice: Undefined variable: hash in newsletter_add_open_rate_image() (line 1145 of /home/v2dl/www/marketing/sites/all/modules/newsletter/newsletter.module).
Notice: Trying to get property of non-object in NewsletterCustom->updateNewsletter() (line 29 of /home/v2dl/www/marketing/sites/all/modules/newsletter/includes/newsletter.custom.inc).
Please help me...
and sending other templates instead of selected one...
Comment #10
phannam1412 CreditAttribution: phannam1412 as a volunteer commentedfor a quick patch, you can modify newsletter.admin.inc:
function newsletter_manual_send($list) {
// Dont send.Just queue it for next cron run
$remaining = variable_get('newsletter_for_next_cron', array());
$remaining[$list->nlid] = TRUE;
variable_set('newsletter_for_next_cron', $remaining);
drupal_set_message(t('Newsletter queued for the next cron run'));
// Add this line of code
newsletter_cron();
return drupal_goto('admin/config/media/newsletter/create-send');
}
Comment #11
fawwad.nirvana CreditAttribution: fawwad.nirvana commentedI followed same step as given in #10
but same issue
Newsletter Lists failed to send because no published nodes found for their terms.