Forums

Integrating Chronoforms with MailChimp

luxhodge 04 Feb, 2014
Hello everyone.

Has anyone successfully integrated chronoforms with MailChimp? I tried some custom PHP in a user registration form so that users are automatically added to a mailing list in MailChimp. However, when I added that code, it wrecked my registration actions, so I decided to put it on their profile edit page. That way once they login and edit their profile, they will be subscribed to the list. I scrapped the custom code for now and decided to try the curl[GH] action instead. I thought maybe it would save me some time. However, I haven't gotten it working yet.

I am running Joomla! 3.1.x with Chronoforoms v4.0.4. I have the URL setup as something like this: http://usX.api.mailchimp.com/1.3/? (where X is the number of the server my chimp account is hosted). Then I set up the parameters like this in the action:
method=listSubscribe
apikey=myAPIKey
id=myListID
email_address={email}
merge_vars[OPTINIP]={IP}
merge_vars[FNAME]={fname}
merge_vars[LNAME]={lname}
merge_vars[STATE]={state}
update_existing=true

If I take the resulting URL (shown in the debugger output) and past it into an empty tab, the subscription is successful. However, if I use the form how I want the user to use it, I get this error: Response: {"error":"Method is not exported by this server","code":-90} .
Here is the curl array as well:
cURL info: Array ( [url] => http://us3.api.mailchimp.com/1.3/ [content_type] => application/json [http_code] => 200 [header_size] => 249 [request_size] => 385 [filetime] => -1 [ssl_verify_result] => 0 [redirect_count] => 0 [total_time] => 0.089195 [namelookup_time] => 0.032965 [connect_time] => 0.053499 [pretransfer_time] => 0.053596 [size_upload] => 250 [size_download] => 61 [speed_download] => 683 [speed_upload] => 2802 [download_content_length] => 61 [upload_content_length] => 250 [starttransfer_time] => 0.089105 [redirect_time] => 0 [certinfo] => Array ( ) [redirect_url] => )

Does anyone know how the curl[GH] action interacts with MailChimp? Maybe it is not correctly sending the info to them? Any ideas would be greatly appreciated. Thanks!

Erik
GreyHead 10 Feb, 2014
Hi Erik,

Sorry, I missed this post earlier :-(

Please see this FAQ

Bob
luxhodge 10 Feb, 2014
No problem Bob! Thanks for the reply!

I took a look at the FAQ and went ahead and purchased your full PDF on the subject. I will let you know how it goes.

Thanks again!

Erik
luxhodge 11 Feb, 2014
Bob,

I worked my way through to page 8 in the PDF for MailChimp. When I use the URL directly (like copy and paste it into my browser address bar), I am subscribed to my list correctly. However, when I use the form, it just goes to my template with a blank page. I am using the ReDirect URL Action. Here is how I have it setup:
URL is: http://mysite.us3.list-manage2.com/subscribe/post-json
In the box I have:
u=myCode
id=myID
EMAIL={EMAIL}
FNAME={FNAME}
LNAME={LNAME}
STATE={STATE}


I will keep at it tomorrow. Just wanted to know if you had any thoughts on the blank window. Is it template related? Not sure what to think. Thanks!
Erik
GreyHead 11 Feb, 2014
Hi Erik,

Do you have a ReDirect User action after the ReDirect URL action? That's needed to do the actual redirection.

If you add a Debugger action what is the link you see and does that work?

Bob
luxhodge 11 Feb, 2014
Doh! I will add the redirect user action. That should do the trick. I will report back either way.

Thanks Bob!

Erik
luxhodge 11 Feb, 2014
Just tried it, but it still doesn't actually redirect. Here is the debugger output (sanitized of course):
1.redirect_url_target_url: http://mydomain.us3.list-manage2.com/subscribe/post-json
2. Redirect URL: http://mydomain.us3.list-manage2.com/subscribe/post-json?u=myList&id=myID&EMAIL=erik%40myemail.com&FNAME=Erik&LNAME=Luxhodge&STATE=Texas

If I copy and past the URL at #2, I get a screen from mail chimp that says: {"result":"success","msg":"Almost finished... We need to confirm your email address. To complete the subscription process, please click the link in the email we just sent you."}, and it works.

I am just being dense I think, but I can't seem to figure out why it doesn't redirect.

Erik
This topic is locked and no more replies can be posted.