Add <script> to X Pro Button

Hi, I’ve searched through the threads but cannot find anything that covers what I’m trying to achieve.

I have styled button elements on the page and wish to maintain this style. I also want one of the buttons to execute a script that generates a modal MailChimp pop-up (subscribe).

The script is as below:

<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.us10.list-manage.com","uuid":"uniqueid","lid":"uniquely","uniqueMethods":true}) })</script>

Is this possible perhaps by adding something to my functions.php in the child theme?

Hey @dmuller,

I’m sorry but I’m not familiar how your code works. I’d recommend that you use ConvertPlus to power your Mailchimp popup. You can use your current button to popup a ConvertPlus Modal just by assigning a class to your button.

For more details about ConvertPlus and its usage instructions, please see the link below.

Thanks.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.