<pre> <script> document.addEventListener('hidden.bs.modal', function (e) { var modal = e.target; // The modal that triggered the event // Check if the modal contains a form var form = modal.querySelector('form'); if (form) { form.reset(); // Reset the form if a form is found } }); </script> </pre>
No comments:
Post a Comment