Request for update to alo_em_add_subscriber() function
-
Hello there
I love this plugin, thank you for developing it.
In my installation, I added some small changes to the alo_em_add_subscriber() function — line 109 of functions/alo-easymail-subscribers.php — to allow for including mailing lists right in the function.
To do this, I simply added an extra parameter to the function — $lists=”|” — so that the entire function name looks like :
alo_em_add_subscriber( $fields, $newstate=0, $lang="", $lists="|" )Then, I simply replaced the ‘|’ value with the $lists variable on line 131 :
'lists' => $lists,This will allow for a very streamlined adding new subscribers to certain mailing lists on custom forms or custom actions. Opens a lot of features and saves the need to use the alo_em_add_subscriber_to_list() function, which in my use case is complicating the workflow. The main issue is that the alo_em_add_subscriber_to_list() function doesn’t have an easy way to be called at the same time as deploying alo_em_add_subscriber_to_list, in a custom action for example (like in my case where I am trying to patch together a zapier set up with a google sheet).
The only thing that people using this function need to be aware of is making sure the $lists value is properly structured with the list values nested in the | characters ( for example : |1|2|3|4| ) — there might be a more clever way to automate this aspect, but for my purposes the way it is with my additions works great.
Would love to see this or something similar rolled out in the next update!
Thank you very much!
Evan
The topic ‘Request for update to alo_em_add_subscriber() function’ is closed to new replies.