How to make ...">

Django Form Template Button

Django accepts and works with a form button in the format:

<input type="submit" value="Submit" />

How to make it work with the following:

<button type="button">Submit</button>
+3
source share
2 answers

Could you explain what exactly you mean by "Django accepts and works with the form button in format"? As far as I know, the difference is in behavior <input type="submit" .../>and <button type="button">...has nothing to do with Django. Django does not care about how the form is submitted from the browser.

This previously posted question may be of interest.

+5
source

Add the following button to submit the form: ("myform" is the identifier of your form)

OnClick = "javascript.document.myform.submit();"

+1

Source: https://habr.com/ru/post/1759660/


All Articles