1👍
✅
You can use the crispy’s as_crispy_field
to achieve that. This also means you will display each field individually by yourself and not the usual looping through the form by the Django template. Your code should look like this
<div class="content-section">
<div class="add-link-wrapper">
<legend class="border-bottom mb-4">
Tilføj produkt til tracking
</legend>
<form method="POST">
{% csrf_token %}
<!-- Show field1 and field 2 here -->
<div class="form-group">
{{form.field1|as_crispy_field}}
</div>
<div class="form-group">
{{form.field2|as_crispy_field}}
</div>
<span>some more html code</span>
<!-- Show field3 here -->
<div class="form-group">
{{form.field3|as_crispy_field}}
</div>
<button class="btn btn-outline-info" type="submit">Add</button>
</form>
</div>
</div>
Source:stackexchange.com