I was using jinja2 to write front page.I got problem when I want to use value from a select tag by only using jinja2 or HTML.
Codes like this:
<select id="pair-select" class="card-title">
<option selected value=1}>one</option>
<option value=2}>two</option>
<option value=3}>three</option>
</select>
<div class="table-responsive">
<table class="table table-striped my-0">
<thead>
<tr>
<th id="deep-table" colspan="2" style="text-align: center;">{{pair-select.val}} </th>
// here I want to use the selected value
</tr>
</thead>
<tbody style="border-right:1px rgb(66, 65, 65) solid;">
{% for order_book in order_books | reverse %}
{% if order_book == pair-select.val %} // also here I want to use selected value
...
...
...
</tbody>
</table>
Can I use it only by jinja2?Otherwise I have to write all tables in javascript which seems to be diffcult.Or is there a better way to do?