By SamDrupal-1 on
Hi all,
At the moment i'm using Mailchimp to send newsletters, so i have a list made in Mailchimp with all my susbcribers.
I got the Mailchimp module installed on my Drupal website and connected it to Mailchimp.com via the API key.
But what i wan't to know is some .php code what can connect to the Mailchimp list, so i can write something that displays five random people from that list (it's for a monthly lottery).
The only thing i would like to know if it is possible to connect to the list of subscribers at mailchimp (and how).
I think it must be possible, since the drupal mailchimp module does it ?
Any help very mutch appreciated.
Grts!, Samuel
Comments
Found some more info
Found some more info but can't yet figure it out.
So I will need my List ID (wich i have).
And i found some code here that could display just the list.
But i have no idea on how to integrate it.
http://stackoverflow.com/questions/5256375/how-do-i-pull-the-subscriber-...
http://apidocs.mailchimp.com/api/rtfm/lists.func.php
_
Don't know if mailchimp exposes any data to views, but if it does, you should be able to make a list random users in views using the 'global: random' sort option and then limit that view to 5 items.
Hi thx for the reply. I got
Hi thx for the reply.
I got another reply on a post i made at the mailchimp module message board.
There someone says that Mailchimp does not import the list to the drupal website.
So i don't think that views is a option.
http://drupal.org/node/1420336
I'l have to actually be able to connect to the database at mailchimp.
Thx!,
Grts!,
Samuel