Mailing list

14 years 2 months ago #120926 by ThePiston
Replied by ThePiston on topic Re:Mailing list
ok, finally here is our answer:

* Subscriber the user to a Newsletter list or a SmartNewsletter list :

INSERT IGNORE INTO `jos_acajoom_queue` (`type`, `subscriber_id`, `list_id`, `mailing_id`, `issue_nb`, `send_date`, `suspend`, `delay`, `acc_level`, `published`) SELECT A.`list_type`, ( SELECT S.`id` FROM `jos_acajoom_subscribers` as S WHERE S.`email` = '[email]' LIMIT 1), A.`id`, 0 , 0, NOW(), 0, 0, A.`acc_level`, 1 FROM `jos_acajoom_lists` as A WHERE A.id = 'YOURLISTID' LIMIT 1;


(replace YOURLISTID by the ID of your list)


* To unsubscribe the user from a list (Newsletter, autoresponder or SmartNewsletter) :

DELETE Q.* FROM `jos_acajoom_subscribers` as S LEFT JOIN `jos_acajoom_queue` as Q ON S.`id` = Q.`subscriber_id` WHERE Q.`list_id` = 'YOURLISTID' AND S.`email` = '[email]';

(replace YOURLISTID by the ID of your list)

Post edited by: ThePiston, at: 2010/01/06 16:36

CB 2.3, CBsubs 4.3, PHP 7.1, J! 3.9.X

Please Log in to join the conversation.

14 years 2 months ago #120994 by coachnet
Replied by coachnet on topic Re:Mailing list
ThePiston, thanks so much for your code - does this mean you have it working now on your site?

I have NO IDEA with SQL, so I'm nervous about playing with this on my live site...

I'm wondering if [email] will take the email address from the user's community builder profile? Or do I need to change this as it suggests on the joobi website?

Post edited by: coachnet, at: 2010/01/07 00:20

Renee Hasseldine
CoachNetwork Founder
Life Coaches | Business Coaches | Executive Coaches

Please Log in to join the conversation.

14 years 2 months ago #121007 by krileon
Replied by krileon on topic Re:Mailing list
coachnet wrote:

ThePiston, thanks so much for your code - does this mean you have it working now on your site?

I have NO IDEA with SQL, so I'm nervous about playing with this on my live site...

I'm wondering if [email] will take the email address from the user's community builder profile? Or do I need to change this as it suggests on the joobi website?

Post edited by: coachnet, at: 2010/01/07 00:20


Create a backup of your database then test the query to see if functioning properly. Yes, [email] will place the users email from Joomla where set. Same applies for [username], etc...


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

14 years 2 months ago #121022 by coachnet
Replied by coachnet on topic Re:Mailing list
I have just tested this and it didn't work for me.

My listid is 2, so the code I inserted on activation is:

INSERT IGNORE INTO `jos_acajoom_queue` (`type`, `subscriber_id`, `list_id`, `mailing_id`, `issue_nb`, `send_date`, `suspend`, `delay`, `acc_level`, `published`) SELECT A.`list_type`, ( SELECT S.`id` FROM `jos_acajoom_subscribers` as S WHERE S.`email` = '[email]' LIMIT 1), A.`id`, 0 , 0, NOW(), 0, 0, A.`acc_level`, 1 FROM `jos_acajoom_lists` as A WHERE A.id = '2' LIMIT 1;


For deactivation:

DELETE Q.* FROM `jos_acajoom_subscribers` as S LEFT JOIN `jos_acajoom_queue` as Q ON S.`id` = Q.`subscriber_id` WHERE Q.`list_id` = '2' AND S.`email` = '[email]';


I tested by subscribing to the plan with these sql actions associated - when I checked in Acajoom, the user was NOT subscribed to list 2.

Any ideas?

Renee Hasseldine
CoachNetwork Founder
Life Coaches | Business Coaches | Executive Coaches

Please Log in to join the conversation.

14 years 2 months ago #121071 by lexxm
Replied by lexxm on topic Re:Mailing list
@ThePiston: I just saw your question, sorry I didn't answer earlier. AcyMailing has 4 different versions (1 free, 3 paid) and the Enterprise version does have the ability to create and mail newsletters from the frontend. I haven't used that feature though, as my clients don't need it, so I don't know how it compares with Acajoom.

But I see you've figured out how to add users to Acajoom lists, so most probably you won't need to switch. Thanks for sharing your code.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.205 seconds