Appear when user clicks on a CSS selector

I’m no expert in programming, I need to show a popups when click over an image I do no how to do. maybe if ther is an example complete

  • Tyler Postle
    • Recruit

    Hey there Fabio,

    Hope you’re doing well today and welcome to the WPMU DEV Community!

    First you will need to go to:

    Popup Pro > Settings. Then activate the Javascript Events add-on.

    Once you have done that you will see a new behavior option when creating a Popup, as seen in my screenshot. The “Appear when user clicks on a CSS Selector” option.

    Now as you see in my example, I have the ID = “#charles-sign-up” this is if maybe I wanted a sign up form to pop up, now in my image code I would do this:

    <img src="http://imageurl.com" id="charles-sign-up" />

    Now when that image is clicked it will trigger the Pop up because it has the same ID :slight_smile:

    You can do it with links like this:

    <a href="#" id="charles-sign-up">Link text here</a>

    The reason we use “#” in the url is because we don’t want clicking the link to actually go anywhere, we want to stay in the same place but just trigger the Pop up.

    Hope this helps Fabio! Let us know if you need any further assistance.

    All the best,

    Tyler

    [attachments are only viewable by logged-in members]