LOOKMAEWDAO Posted September 25, 2022 Share Posted September 25, 2022 (edited) php/html/css3 : I use a form to register for a show event. The button "Send" is at the bottom of the form. I would like to use a modal from another button in the form for showing eventually the registration rules. But that doesn't work. The modal opens and closes directly ! My question is thus : is it possible to use a modal inside a form ? Thanks. Edited September 25, 2022 by LOOKMAEWDAO Link to comment Share on other sites More sharing options...
dsonesuk Posted September 26, 2022 Share Posted September 26, 2022 Yes! If its a static modal the button normally in the form would simply set the display on modal to display: block/flex instead of display: none. If it has to dynamically load content, pressing the button it would need to preload content, then set to display: block/flex. If the form does not submit by ajax, the form will reload the page causing the modal to its default state on page load. Link to comment Share on other sites More sharing options...
LOOKMAEWDAO Posted September 27, 2022 Author Share Posted September 27, 2022 OK. Thanks dsonesuk ! It's seems to work fine using Bootstrap libraries.... CSS3 should be update in the same way.... Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now