How do I sending in random order

Advanced Questions & Problems

How do I sending in random order

Postby sugarfree » 9:35am, Tue 18 Sep, 2012

We have a huge list of recep. and sending in a random order is important because receiving servers will not accept mails coming in to fast from the same sender.

To randomize the sending order would be one trick to get around the problem I guess. But how do i accomplish sending in random?

Thanks /Mattias
sugarfree
phpList newbie
 
Posts: 1
Joined: 9:23am, Tue 18 Sep, 2012

Re: How do I sending in random order

Postby whatshisname » 8:00pm, Sat 16 Mar, 2013

Giving this a bump because this is important for me, as well, and for the same reason.
whatshisname
phpList newbie
 
Posts: 2
Joined: 7:44pm, Thu 24 Jan, 2013

Re: How do I sending in random order

Postby javerleo » 10:18pm, Mon 09 Mar, 2015

Bump

This is a key feature. Looking further for instuctions to randomize order.
javerleo
phpList newbie
 
Posts: 2
Joined: 10:16pm, Mon 09 Mar, 2015

Re: How do I sending in random order

Postby duncanc » 6:36am, Tue 10 Mar, 2015

phplist doesn't provide a way to alter the order of sending emails.

You can look at domain throttling, see the config.php file, if you want to restrict the rate at which phplist sends to each domain, but in my experience it slows down the actual send rate significantly.
duncanc
Moderator
 
Posts: 2440
Joined: 6:34am, Sat 08 May, 2010
Location: London

Re: How do I sending in random order

Postby javerleo » 3:03pm, Tue 10 Mar, 2015

Thanks for you reply Duncan.

I understand that phpList doesn't include that feature. Could you guide me to the scripts that contain the sending logic? Some developer guide? I have some PHP progamming knowledge, so I will try to make the modification to shuffle the batch to deliver on each run.

Regards.
javerleo
phpList newbie
 
Posts: 2
Joined: 10:16pm, Mon 09 Mar, 2015

Re: How do I sending in random order

Postby duncanc » 5:25pm, Tue 10 Mar, 2015

The sql that selects subscribes is in the file admin/actions/processqueue.php at line 795.
duncanc
Moderator
 
Posts: 2440
Joined: 6:34am, Sat 08 May, 2010
Location: London

Re: How do I sending in random order

Postby billygk » 10:32am, Tue 28 Apr, 2015

Thanks to duncanc, this is how I did it.

in file admin/actions/processqueue.php
around line 860
added order by rand()


Original
Code: Select all
    if ($num_per_batch > 0) {
      $query .= sprintf(' limit 0,%d',$num_per_batch);


Change to
Code: Select all
    if ($num_per_batch > 0) {
        $query .= sprintf(' order by rand() limit 0,%d',$num_per_batch);



Hope it helps someone @ some point
billygk
phpList newbie
 
Posts: 2
Joined: 10:23am, Tue 28 Apr, 2015


Return to Advanced Questions & Problems

Who is online

Users browsing this forum: No registered users and 2 guests