0

How would one create a hidden form on a web page and only open the form when the button is clicked?

2
Contributors
3
Replies
24
Views
2 Years
Discussion Span
Last Post by diafol
0

This is likely to be a javascript hide and show affair (toggle display).
Else it could be an Ajax call to get the form from the server and update the html page.

I'm assuming that you do not want anything to happen other than to show a form on button click? If so, you can set the form's display: none in css.

Then when you click the button, have the click event change the display of the form to block.

0

i need a form that is hidden until the user clicks a date on a calendar. onky Then the form will be visible and have a field for the day that way pressed on submit the form would go back to being invisible.

not sure how to implement this

0

So are you looking for a javascript modal form (like a lightbox/popup)?

There are hundreds of implementations of this. If you're using jQuery and more importantly, jQueryUI - there's a modal form. If you're using a front-end framework like Twitter Bootstrap, then there's a modal form example. Hell, just search for "javascript modal form" and you'll get more hits than an overrated middling 60/70's band with bad haircuts from Liverpool.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.