30 lines
1.0 KiB
HTML
30 lines
1.0 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<title>Dropdown Example</title>
|
|
</head>
|
|
<body>
|
|
<h1>Select a Relationship and Person</h1>
|
|
<form action="/" method="post">
|
|
<label for="relationship_type">Relationship Type:</label>
|
|
<select name="relationship_type" id="relationship_type">
|
|
<option value="">Any</option>
|
|
{% for relationship in relationships %}
|
|
<option value="{{ relationship }}" {% if request.form.get('relationship_type') == relationship %}selected{% endif %}>{{ relationship }}</option>
|
|
{% endfor %}
|
|
</select>
|
|
|
|
<label for="person">Person:</label>
|
|
<select name="person" id="person">
|
|
<option value="">Any</option>
|
|
{% for person in persons %}
|
|
<option value="{{ person }}" {% if request.form.get('person') == person %}selected{% endif %}>{{ person }}</option>
|
|
{% endfor %}
|
|
</select>
|
|
|
|
<button type="submit">Submit</button>
|
|
</form>
|
|
</body>
|
|
</html>
|