manage subscription with PHP wrapper library

Highlighted
New Member

manage subscription with PHP wrapper library

I am finding documentation or examples or sample code that help me to manage subscription for various list in constant contact account. Proccess that I follow from my website is when user come to site he entered his email address and list city name (list name in constant contact). He can enter his email id for one list only at a time. If he want to subscribe for another list then he has to enter his email address again and list for which he want to sub scribe.


I need your help. pls help me ASAP...!!

1 REPLY 1
Highlighted
CTCT Employee

creating and updating a contact

Hello,



The way that you would want to create this with our API's and using the PHP wrapper, is that you would want to first check to see if the contact already exists, using the searchByEmail function. If the contact exists it will return an array with the contacts information in it. If the contact does not exist it will return false. If the contact does not exist, then you would want to use the createContact function to add the contact to the list. This will require at minimum the contacts email address and the list URI that you want the contact to be added to.



If the contact does exist, you would want to use updateContact instead of createContact, and just add an additional list URI to the list array inside of the contact object.



If you have any questions about this please let me know.



Regards

Benjamin Soder
NOC Analyst
Constant Contact
Developer Portal

View API documentation, code samples, get your API key.

Visit Page

Constant Contact Would Like To Hear From You!

We want to hear from customers like you about your favorite features and how they have helped your business or organization. Tell us by answering a few questions in...

Read More
Featured