This post is a step by step to get Autoresponders working in your PHPList installation.
PHPList is a mailing list software that gets installed on your web server. If you don’t know what PHPList is, you don’t need this article 🙂
As you probably know, autoresponders, aka “drip marketing” are a very powerful tool in being able to create more one-on-one style relationships to your customer or fan base. Basically, an autoresponder sends out a message (or series of messages) to new list members, based on when they sign up. For example, I might enter my email address to get a free download, and the first message I receive is with my download link. A day later, I might get a follow up that says “hey did you like the download?”. A couple days later I might get an offer or maybe just a link to a blog post (like this one! lol), and so on.
PHPList is very powerful and awesome, but out of the box doesn’t have an autoresponder. Well these people have saved the day by creating an autoresponder plugin.
However, “those people” are very busy, and although there is SOME documentation, there is not a proper step by step, how to get this running tutorial. So I’m doing THIS post. Now this really isn’t very complicated, so it should be painless. Here we go. I’m assuming you’ve installed PHPList 3.something and have it running, messages succeed in getting sent, etc. So…
Step 1: Dependencies
- Make sure PHP is 5.3 or later.
- Install the Common Plugin v3:
- Go to yourdomain.com/lists/admin. Login.
- Go to config->manage plugins.
- Under “package plugin URL” enter this url: https://github.com/bramley/phplist-plugin-common/archive/master.zip and click “install plugin”. There are also instructions for manually installing at the link above.
- Check that it’s enabled by scrolling down and finding it. You should see green thumbs up under the 2nd column, “enabled”.
- If not, click the “enable” button.
Step 2: Install autoresponder plugin
Actually install the autoresponder plugin by entering the following url in “package plugin URL” under config->manage plugins:
https://github.com/bramley/phplist-plugin-common/archive/master.zip
Check that this is enabled the same as before.
Step 3: Using autoresponder
- Make a campaign. Navigate to “campaigns->send a campaign”.
- Click “start a new campaign”
- Enter your message details, click “save and continue editing”
- Go to the scheduling tab, and make sure “start sending after” is a date far in the future. This is important! Your responses won’t send after that date!
- Go to the lists tab, and pick the lists you want to send to. Only subscribers who subscribe to THOSE lists will get this message, and you HAVE to set this, or nothing will happen.
- Now DO NOT send or add to queue <—- also very important
- Instead, click “save as draft”
- Create an autoresponder
- Navigate to “campaigns->manage autoresponders”
- Click “add”
- Enter a description and pick your new draft campaign from the dropdown marked “select the draft message to send”
- select a delay and if you want an action like a move to another list to take place.
- Keep “Only send to new users” checked! Other wise you’ll keep sending this thing to everybody. <— important
Step 4: Making it actually work
You may be inclined now to think everything will automagically happen. It will not. Two more steps need to happen EVERY TIME an autoresponse is to be sent. These two steps are:
- “Process autoresponders”
- “Process queue”
There are two ways for those TWO processes to happen – you can either do them manually:
- Login to lists/admin
- navigate to “campaigns->process autoresponders”
- navigate to “system->send the queue”
At that point, the queue will send to everyone who’s up for sending. This may be nobody, in which case step 1, “process autoresponders” will have said no messages to send. If there are messages to send, it will have told you “1 message processed” or whatever number of messages. That’s MESSAGES, not subscribers.
You may have noticed by now that doing it manually does not, per se, constitute “auto” responding 🙂 The second way to make it happen is with a cron job. This is not something I can step you through as easily, because your server situation will vary. For me, I use icdsoft to host. This is a shared host, so what I do is this:
- Login to control panel via mydomain.com/cp
- go to the “cron jobs” tab
- point a cron job to a .sh script I keep in a private directory, and run it every 15 minutes.
- that shell script contains the following:
- #!/bin/bash
/usr/local/bin/php.cli /mypath/www/lists/admin/index.php -m Autoresponder -p process -c /mypath/www/lists/config/config.php
/usr/local/bin/php.cli /mypath/www/lists/admin/index.php -p processqueue -c /mypath/www/lists/config/config.php - you might also consider processing bounces here – or in another cron job.
- Here is a decent resource with examples of cronjobs for phplist: http://docs.phplist.com/CronJobExamples.html
Step 5: Test
Obviously I recommend a lot of testing. I create a few autoresponders with maybe a few minute delay, create a few email addresses in my host and sign up to my own test list, and watch to see if my autoresponders are working. If there is trouble you can’t sort out, I find the people over at http://discuss.phplist.com quite helpful, and the developer of the autoresponder plugin might even respond to help you! In fact, *I* might even! 🙂
Cheers!
Aaron