H
H
hooli-gun2021-10-19 15:07:49
WordPress
hooli-gun, 2021-10-19 15:07:49

How to add contact form 7 attribute?

How to add the data-dismiss="modal" attribute to a button in a contact form?

<input type="submit" value="Send" class="wpcf7-form-control wpcf7-submit" id="modal-close">

[submit id:modal-close "Send"]

document.getElementById('modal-close').attr("data-dismiss","modal");

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Anton Litvinenko, 2021-10-19
@hooli-gun

Instead of the submit shortcode, use the standard button type submit and write any attributes in it
here
https://stackoverflow.com/questions/46274317/how-t...
well, as an option, you can add using js

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question