This commit is contained in:
micaiah parker 2018-08-10 18:20:49 -04:00
parent 55b93a18f9
commit 52b5c6bd24
2 changed files with 4 additions and 4 deletions

4
app.py
View File

@ -1,4 +1,4 @@
from flask import Flask, render_template, jsonify, redirect
from flask import Flask, render_template, jsonify, redirect, url_for
from char import get_stats, data
app = Flask(__name__)
@ -15,7 +15,7 @@ def _get_stats():
def get_data():
return jsonify(data)
@app.route('/submit', methods=["POST"])
@app.route('/submit')
def submit():
return redirect(url_for('index'))

View File

@ -3,7 +3,7 @@
<div class="grid">
<div class="cell -6of12">
<div class="cell -3of12">
<form class="form" action="/submit" method="POST">
<form class="form" action="/submit" method="GET">
<fieldset class="form-group">
<label for="username">NAME:</label>
<input type="text" id="name" class="form-control">
@ -83,4 +83,4 @@
</div>
</div>
</div>
{% endblock %}
{% endblock %}