Related to #7945, Mailchimp changed their popup Javascript code again, and this causes the Mailchimp widget to not convert it correctly into the proper shortcode.
Previously, it looked like:
<script type="text/javascript" src="//downloads.mailchimp.com/js/signup-forms/popup/embed.js" data-dojo-config="usePlainJson: true, isDebug: false"></script><script type="text/javascript">require(["mojo/signup-forms/Loader"], function(L) { L.start({"baseUrl":"mc.us8.list-manage.com","uuid":"be06c2a596db91bfe4099fde8","lid":"b47399ad05"}) })</script>
Now, it looks like:
<script type="text/javascript" src="//downloads.mailchimp.com/js/signup-forms/popup/unique-methods/embed.js" data-dojo-config="usePlainJson: true, isDebug: false"></script><script type="text/javascript">window.dojoRequire(["mojo/signup-forms/Loader"], function(L) { L.start({"baseUrl":"mc.us8.list-manage.com","uuid":"be06c2a596db91bfe4099fde8","lid":"08cf5fa008","uniqueMethods":true}) })</script>
Saving the the above code doesn't convert into the shortcode, or result in the popup showing up on the site.
Note that the src value has changed with the additional /unique-methods/ subfolder, require was changed to window.dojoRequire and uniqueMethods":true was added at the end. A workaround back then was to simply change the src URL, but this time it doesn't work. Manually creating the shortcode with the baseURL, uuid and lid values still works, though.
An update on this widget would be fantastic. Thank you in advance!
Thanks for your work on this @jeherve we also have a report of this on WP.com so commenting to make sure this fix gets backported :)
https://en.forums.wordpress.com/topic/mailchimp-html-snippet-for-subscribe-popup-is-being-stripped
Some additional testing information that might be helpful on this issue.
Tested on a WordPress.com site with a Premium Plan and custom domain.
The before code looked the same as referenced above.
But the after code looked like:
<a href="//downloads.mailchimp.com/js/signup-forms/popup/unique-methods/embed.js">//downloads.mailchimp.com/js/signup-forms/popup/unique-methods/embed.js</a>window.dojoRequire(["mojo/signup-forms/Loader"], function(L) { L.start({"baseUrl":"mc.us16.list-manage.com","uuid":"7fd6eb5d6e7da5b3c14b87112","lid":"cbea7a4be4","uniqueMethods":true}) })
Based on the suggested work-around of:
[mailchimp_subscriber_popup baseUrl='$baseURL' uuid='$uuid' lid='$lid' usePlainJson='true' isDebug='false']
It was tested and worked on a couple of sites formatted as above, but didn't work on another site.
Further testing resulted in it working when the single quotes were replaced with double quotes and it has worked formatted like this:
[mailchimp_subscriber_popup baseUrl="$baseURL" uuid="$uuid" lid="$lid" usePlainJson="true" isDebug="false"]
Wasn't sure if this could be useful, so wanted to share. :-)
reported in #1413476-zen
Reported on #1432034-zen as well.
Most helpful comment
Some additional testing information that might be helpful on this issue.
Tested on a WordPress.com site with a Premium Plan and custom domain.
The before code looked the same as referenced above.
But the after code looked like:
Based on the suggested work-around of:
It was tested and worked on a couple of sites formatted as above, but didn't work on another site.
Further testing resulted in it working when the single quotes were replaced with double quotes and it has worked formatted like this:
Wasn't sure if this could be useful, so wanted to share. :-)