This is my code. I get an error that the heading has already been sent. include($_SERVER['DOCUMENT_ROOT'].'/application/library/cc_class.php'); $ccContactOBJ = new CC_Contact(); $ccListOBJ = new CC_List(); $contactXML = ' <entry xmlns="http://www.w3.org/2005/Atom"> <title type="text"> </title> <updated>2008-07-23T14:21:06.407Z</updated> <author></author> <id>data:,none</id> <summary type="text">Contact</summary> <content type="application/vnd.ctct+xml"> <Contact xmlns="http://ws.constantcontact.com/ns/1.0/"> <EmailAddress>'.$email.'</EmailAddress> <OptInSource>ACTION_BY_CONTACT</OptInSource> <ContactLists> <ContactList id="http://api.constantcontact.com/ws/customers/asmithinvt/lists/1" /> </ContactLists> </Contact> </content> </entry> '; if (!$ccContactOBJ->addSubscriber($contactXML)) { //nothing } else { header("location: ".HTTPABSOLUTEPATH."index.php?go=thankyou"); }
... View more