Салями алекум. Как присвоить значение переменной в выпадающем списке?
Вот код, но он не работает -
<select name="select_0">
{% for key in jsonfile['Countries'].items() %}
<option value="select_1" {% if key[0]== "Italy" %} {{jsonfile['Countries']['Italy']}} {% else %} {{jsonfile['Countries']['Spain']}} {% endif %}>{{key[0]}}</option>
{% endfor %}
</select>