Setup Aweber Email Parser

5ad3izx5tyarjaj I will show you how to setup AWeber Email Parser.
To those of you who do not know what Aweber is, it is an email marketing software that allows you to store email addresses and other important stuffs to people who uses your product or whatever purpose you have.

So my idea here is that everytime a user registers in my website, I will get their email address as well as their name then store it in AWeber.

This is the front end of AWeber

AWeber uses a basic Regular Expression so no need to be rattled ( I was too rattled, so I was forced to learn RegEx :) ).

The default setup of AWeber parse is like this, but I changed it.

Rule 1:: \n[>\s]*Email:\s+(.+?)\n Match:
Store in:
Rule 2:: \n[>\s]*Name:\s+(.+?)\n Match:
Store in:

Looking at the image above(not the table), On the Trigger Rule textinput, change the “aweber” into the email address that you wrote when you created a list. Then change the “myDomain” to your domain name.

Just copy this one as your Rule1:  Name:[ ]*([^\n]+)

Now in your php file:

function SendEmailToAweber( $name, $email_address ) {
      $to = ""; #this is the same email address that you wrote when you created a list
      $subject = "Store Email Address from";

     #this is important because we told our regular expression to have a newline above it.
     $message .= "\n";
     $message .= "Name: ".$name;

     $headers = 'MIME-Version: 1.0' . "\r\n";
     $headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
     $headers .= 'From: '.$name." <".$email_address."> \r\n";

     mail( $to, $subject, $message, $headers );

Everytime you run this function, it will send an email to AWeber then it will parse it using the configuration tha we set up. Now you are golden! :) So that’s it! That’s how easy to setup AWeber email parser. Hope this helps someone. Have a happy coding :)