[Fixed]-Is it possible to submit a GET form to two different views with two buttons?

1👍

Why don’t u use the formaction= tag attribute in your button to override the form action?

<form method="get" action="firstView">
  <input ...
  <input ...
  <button ...>Submit to first view</button>
  ..
  ..
  <button formaction="{% url 'myapp:secondView' %}" ...>Submit to second view</button>
</form>

It is a HTML5 attribute but it is supported by all the major browsers.

FormAction browser support

Leave a comment