How to show hidden div after hitting submit button in form?

前端 未结 3 1980
野的像风
野的像风 2021-01-21 11:53

I have simple HTML form with submit button. After hitting this button I would like to the see div#my_id which is not visible before.



        
3条回答
  •  独厮守ぢ
    2021-01-21 12:20

    Your submit button will submit the form it is placed in using the defined action and method. Any arguments / fileds in the form will be included as query parameters.

    The reason you are not seeing your div appear, is because the click results in the page being reloaded. After the reload the div will be hidden again.

提交回复
热议问题