Using Constant Contact API

Posted on 2006-05-05
Last Modified: 2016-03-18

I have a registration form on a site that populates info into my database.  

Now, I would like to use the Constant Contact API to add my users to my email list, in addition to registering them with my site. .

I do not quite understand how to do this because I have seen some posts talking about writing a .com component also.

So, Constant contact with allow a get or post to their api URL:
Here is an example with a get although I think I would like to use post.

Can someone point me in the rirght direction? How can I do 2 posts with one form.
Question by:baybook
    LVL 22

    Accepted Solution

    here is a quick example on how to post using a technique called remote scripting.  youwould build your form key/value pairs then send it to the url above.

    <%@ Language=vbScript%>
     DataToSend = "id=1"
     dim xmlhttp
         set xmlhttp = server.Createobject("MSXML2.ServerXMLHTTP")
     xmlhttp.Open "POST","http://server/test.asp",false
     xmlhttp.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
     xmlhttp.send DataToSend
     Set xmlhttp = nothing

    Author Comment


    Thanks for pointing me in a direction.  What does the datatosend do?  I'm guessing I can put what would have been a "querystring" if I can using the post method.  I will play around with it.

    LVL 22

    Expert Comment

    the datatosend variable is getting a value set to it above.

    DataToSend = "id=1"

    you would construct this just like a querystring would look with & signs delimiting.

    Featured Post

    Better Security Awareness With Threat Intelligence

    See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

    Join & Write a Comment

    I recently decide that I needed a way to make my pages scream on the net.   While searching around how I can accomplish this I stumbled across a great article that stated "minimize the server requests." I got to thinking, hey, I use more than one…
    I was asked about the differences between classic ASP and ASP.NET, so let me put them down here, for reference: Let's make the introductions... Classic ASP was launched by Microsoft in 1998 and dynamically generate web pages upon user interact…
    This video is in connection to the article "The case of a missing mobile phone (". It will help one to understand clearly the steps to track a lost android phone.
    Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

    734 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    19 Experts available now in Live!

    Get 1:1 Help Now