Changes between Initial Version and Version 2 of Ticket #35647
- Timestamp:
- Jul 31, 2024, 10:37:19 AM (4 months ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #35647 – Description
initial v2 1 1 I was Trying to integrate HTMX into my django application's frontend. and noticed a weird and what seems like a breaking issue. 2 2 Following is the html code that I have in my html file being rendered: 3 4 {{{ 3 5 <form 4 6 hx-post="{% url 'batch_delete' pk=batch.id %}" … … 15 17 </button> 16 18 </form> 19 }}} 17 20 Following is what is seen my inspecting Element in my Browser. 21 22 {{{ 18 23 <form hx-post="/batches/22/delete/" hx-trigger="submit" hx-target="#batchesListCard" hx-swap="innerHTML" hx-on::before-request="$(this).closest('.modal').modal(hide)"></form> 19 24 <input type="hidden" name="csrfmiddlewaretoken" value="csrf_value"> … … 21 26 Yes 22 27 </button> 23 28 }}} 24 29 As you can see, the form is being auto-closed by the templating engine, 25 30 The error however isnt in every form, It is happening to the form(with no user input) that is used with htmx to be used as a trigger.