Add existing contact to another email list

M-NCPPC
Regular Participant

Add existing contact to another email list

I am using the ColdFusion version of the sample code. Adding a new contact is working fine, but while I try to add a existing contact to another list, I don't get any error message, it always say"Contact XXXXXXXX Added", but it is actually not added to the new email list. How can I change the code and update the list selection of this existing contact?

 

14 REPLIES 14
Ryan_D
Employee

Hey,

 

In order for me to troubleshoot the issue you will need to supply the code that you are using.  I would remove any credentials inside however.

Ryan Davis
Quality Engineer
M-NCPPC
Regular Participant

I just download the CF zip code from http://community.constantcontact.com/t5/Documentation/Code-Samples/ba-p/25019, and install on my CF server, the only thing I change is the application file to plug in my constant contact username, password and API code. the Problem is only can added new contact, but if the contact is already in one of list, it cannot be added to a new list, and it always say"new contact added" instead of "contact already existing".

I will get a test environment set up and check this out for you.  I apologize that the samples are not working for you.

Ryan Davis
Quality Engineer

Hey,

 

I just set up Coldfusion 9 on my sandbox environment and tested a fresh download of our sample forms against my account.  I was able to create a new contact, change their lists as well as other information multiple times with no issues.  I believe that there may be something misconfigured on your server. 

 

What version of CF are you running?

 

 

Ryan Davis
Quality Engineer
M-NCPPC
Regular Participant

I have CF 8 on my local PC and production server, the local PC is working but cannot add existing contact to a new list. Same code is not working on production Server, always give me this error message:

An error occured while Parsing an XML document.
Content is not allowed in prolog.
 
   
10 :     <cfset LOCAL.xmlContent = XmlParse(doServerCall("get", "#APPLICATION.apiPath#/lists"))>

I will try to install Coldfusion 8 on my local machine and see if I can replicate.

Ryan Davis
Quality Engineer
M-NCPPC
Regular Participant

forgot one thing, the local PC is working for me. I am using CF 8 developer version as a standalone web server. the production is not working I am using CF8 enterprise with IIS.

M-NCPPC
Regular Participant

anything to do with SSL certificate?

Hey,

 

I have tested in CF8 and CF9 in both Windows Server 2003 and Windows Xp environments.  They both worked with out any modification.  My CF are developer editions as I do not have access to enterprise edition.  As far as the SSL, I am going to try with to work with an outside host but I will not know how things are set up.  I know the problem is somewhere on your side but I am unsure where.

Ryan Davis
Quality Engineer
M-NCPPC
Regular Participant

Thank you for your help. I don't know what is the next step I need to do. Cannot figure out.

Hey,

 

I have tried on a shared hosting server as well and was not able to replicate your issue.  I do not have an SSL on any of my environments, howerver I am unaware of how that would effect only our sample forms.

Ryan Davis
Quality Engineer
M-NCPPC
Regular Participant

I will try to re-download the sample code and install it on my laptop, see if it is working? I have CF 8 on the laptop.

M-NCPPC
Regular Participant

I installed the CF 9 developer free version on my laptop with IIS, and the sample code is working fine totally. The CF 8 is still no luck for me. I don't know what is the reason. The problem is my production server is still running CF 8.

Developer Portal

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

Visit Page