Site logo

Archived topic

Add a shortcode to a button

1 reply · Started by Gary on May 30, 2022

Viewing posts 1–2 of 2

Hi,

I have built a new button and am looking to use it to launch a pop-up form (which will sit in front of the website). I am using forminator and hustle to do this and following a guide - https://wordpress.org/support/topic/adding-forminator-to-a-button/

I can't work out how to add the new shortcode to a button, which will allow me to launch the new form. Is this possible using GeneratePress?

Thanks in advance!

Hi there,

so i tracked this down in the Hustle Docs:

https://wpmudev.com/docs/wpmu-dev-plugins/hustle/#click

its where you can set the Trigger ( to open the Pop Up ) using a Click event.
So you won't want: Render a trigger button
Instead you will only want" Click on existing element and in the CSS Selector(s) field provided you can add your own class eg. open-popup

Now if you use GenerateBlocks to add your button, with the button selected go to Advanced > Additional CSS Class(es) add your CSS selector eg. open-popup

This archived topic is closed to new replies.