Notice: These forums are now retired and closed. For active support, please Submit a Ticket or visit our official WordPress.org community pages.
Kadence Theme | Kadence Blocks | Starter Templates | WooCommerce Email Designer | Ascend | Virtue | Pinnacle

Kadence Blocks Pro – trigger modal with javascript?

Home / Forums / Membership Forums / Kadence Blocks Pro – trigger modal with javascript?

This topic is: Resolved
[Resolved]
March 25, 2020 at 10:58 pm

Hi there,

First, thanks for such an amazing plugin. Second, my non-jQuery javascript isn’t great. I was trying to figure out how I might trigger a modal block to display with javascript and cookies. Basically I want to have a modal display provided a cookie isn’t set to remind a site visitor of site policy. I set an element id of “harassment” and can run:
MicroModal.show(‘harassment’) in the console and trigger it, but if I do that, the modal close button doesn’t work, so I feel like I’m initiating the show of the Modal wrong. What function should I call to manually trigger a modal to display? Thanks in advance!

  • The forum ‘Membership Forums’ is closed to new topics and replies.