• Thomas

    (@thomaspapachuloch)


    I am using the mailchimp plugin on my ajax driven website.

    I include the signup form directly in my template with:

    mailchimpSF_signup_form();

    I also see that in <head> the mailchimp.js is loaded.
    But if I click on the “Signup” button in the form, the mailchimp.js is not executed. Strange is, that when I copy the whole code of mailchimp.js directly in a <script></script> tag in the template, the whole thing works.

    And something other: By the wp_head(); function the mailchimp plugin includes jquery (from includes/js/jquery/) into my head. Before I included jquery (1.10.2) on a static way (not state of the art), so I removed this one and hoped it will work properly, because jquery is included now by wp_head(); But with that version of jquery (1.10.2) fomr wordpress, jquery is not loaded, everything is undefined.

    Thx for your feedback or help.
    Thomas

    http://wordpress.org/plugins/mailchimp/

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hey Thomas,
    Thanks for writing in. We’re definitely happy to help however we can. In this case, though, we would need a bit more information to be able to try and find what the cause may be. Can you possibly provide a link to your site so we can take a look at it?

    Thanks,
    Gabe

    Thread Starter Thomas

    (@thomaspapachuloch)

    Hi Gabe

    The link to the site is: http://www.landlieberadio.ch/#newsletter

    I think I figured out what problem #1 could be: mailchimp.js loaded only once at the initial first request of the page. if the form fields are not there, the form is not bound to the script. because the content of newsletter page is loaded by ajax, there is no new page reload…and mailchimp.js is not respndonding. thats how it looks now.

    if I copy the whole script into my ajax page at the bottom, then it works.

    thank you in advance!
    thomas

    Hi Thomas,

    I’m glad you were able to solve the problem. When I tested your form, it seems to work correctly. Since you’re using an ajax site, copying the whole script might work better. But since you’re copying the script future updates to the plugin might cause problems. If you’re setting up a custom page, as an alternative you might consider using the MailChimp embed code instead. The javascript for the embed code is in the code, and it might avoid these problems with loading. Here’s a link to find that code in your MailChimp account. It’s up to you if you want to use it.

    With your second problem, I’m still seeing jquery loaded in the head the static way. You might want to check out this page on properly adding jquery to your theme. http://matthewruddy.com/using-jquery-with-wordpress/

    -mcd

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘jquery plugin not responding’ is closed to new replies.