Skip to content
Snippets Groups Projects
Commit b29906a0 authored by Felix Chadwick-Smith's avatar Felix Chadwick-Smith
Browse files

Merge branch 'master' into 'main'

fixed get request fro add project paeg

See merge request !32
parents 29b58d97 de7098ae
No related branches found
No related tags found
1 merge request!32fixed get request fro add project paeg
No preview for this file type
......@@ -13,10 +13,9 @@
background-size: cover;
}
</style>
</head>
<body class="home-page">
<!---https://realpython.com/flask-project/#create-a-virtual-environment--->
<!---https://realpython.com/flask-project/#create-a-virtual-environment--->
<nav>
<ul>
<li><a href="{{ url_for('home') }}">Home</a></li>
......@@ -27,32 +26,36 @@
<li><a href="{{ url_for('contact') }}">Contact</a></li>
</ul>
</nav>
<h2>Add Project</h2>
<!---https://realpython.com/flask-project/#create-a-virtual-environment--->
<form method="POST" action="{{ url_for('add_project') }}">
{% with messages = get_flashed_messages() %}
{% if messages %}
<ul class="messages">
{% for message in messages %}
<li>{{ message }}</li>
{% endfor %}
</ul>
<!---https://realpython.com/flask-project/#create-a-virtual-environment--->
<div class="form-container">
<h2>Add Project</h2>
<form method="POST" action="{{ url_for('add_project') }}">
{% with messages = get_flashed_messages() %}
{% if messages %}
<ul class="messages">
{% for message in messages %}
<li>{{ message }}</li>
{% endfor %}
</ul>
{% endif %}
{% endwith %}
{% if form %}
{{ form.csrf_token }}
<div class="form-group">
<label for="title">Project Title</label>
{{ form.title(class="form-control", placeholder="Enter project title") }}
</div>
<div class="form-group">
<label for="description">Project Description</label>
{{ form.description(class="form-control", placeholder="Enter project description") }}
</div>
<div class="form-group">
{{ form.submit(class="btn btn-primary") }}
</div>
{% endif %}
{% endwith %}
{% if form %}
{{ form.csrf_token }}
<div class="form-group">
{{ form.title.label }}
{{ form.title(class="form-control", placeholder="Enter project title") }}
</div>
<div class="form-group">
{{ form.description.label }}
{{ form.description(class="form-control", placeholder="Enter project description") }}
</div>
<div class="form-group">
{{ form.submit(class="btn btn-primary") }}
</div>
{% endif %}
</form>
</form>
</div>
</body>
</html>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment