Button in modal with 2 functions

I designed a button in a modal.
The functions of this button are:

  • link to an URL in the ssame page (target: “/#fp_pricingtable”)
  • close the modal
    I didn’t find out how to affect these 2 functions to one button.
    Could you help me please.

This should be possible.
Did you try to enter #fp_pricingtable instead of /#fp_pricingtable?

1 Like

The link to target is ok, but the modal is not close after!
I am working on this code:
“<“button type=“button” onclick=“window.location.href=‘#fp_pricingtable’” data-dismiss=“modal-c449ae8”>Close and go to pricing</button”>”
modal-c449ae8 is the id of the modal
But something goes wrong!

You need to give your modal close button the anchor link of your target section:

image

In addition, just add this attribute to your modal close button:

image

Let me know your results.

Seriously, you are the best I have never meet or read!
Thank you again!
You are really precious for this community and a real place-value for Cwicly. You saved me so often…

PS: that runs well!

1 Like

Appreciate your kind words, thanks @weedor.
Glad it worked out for you :+1: