Browse Source

remove unnecessary form action attributes

pull/1927/head
David Lord 9 years ago
parent
commit
cd1a9b7d54
  1. 2
      docs/patterns/fileuploads.rst
  2. 2
      docs/patterns/flashing.rst
  3. 2
      docs/patterns/wtforms.rst
  4. 2
      docs/quickstart.rst

2
docs/patterns/fileuploads.rst

@ -71,7 +71,7 @@ the file and redirects the user to the URL for the uploaded file::
<!doctype html> <!doctype html>
<title>Upload new File</title> <title>Upload new File</title>
<h1>Upload new File</h1> <h1>Upload new File</h1>
<form action="" method=post enctype=multipart/form-data> <form method=post enctype=multipart/form-data>
<p><input type=file name=file> <p><input type=file name=file>
<input type=submit value=Upload> <input type=submit value=Upload>
</form> </form>

2
docs/patterns/flashing.rst

@ -78,7 +78,7 @@ And here is the :file:`login.html` template which also inherits from
{% if error %} {% if error %}
<p class=error><strong>Error:</strong> {{ error }} <p class=error><strong>Error:</strong> {{ error }}
{% endif %} {% endif %}
<form action="" method=post> <form method=post>
<dl> <dl>
<dt>Username: <dt>Username:
<dd><input type=text name=username value="{{ <dd><input type=text name=username value="{{

2
docs/patterns/wtforms.rst

@ -108,7 +108,7 @@ takes advantage of the :file:`_formhelpers.html` template:
.. sourcecode:: html+jinja .. sourcecode:: html+jinja
{% from "_formhelpers.html" import render_field %} {% from "_formhelpers.html" import render_field %}
<form method=post action="/register"> <form method=post>
<dl> <dl>
{{ render_field(form.username) }} {{ render_field(form.username) }}
{{ render_field(form.email) }} {{ render_field(form.email) }}

2
docs/quickstart.rst

@ -784,7 +784,7 @@ sessions work::
session['username'] = request.form['username'] session['username'] = request.form['username']
return redirect(url_for('index')) return redirect(url_for('index'))
return ''' return '''
<form action="" method="post"> <form method="post">
<p><input type=text name=username> <p><input type=text name=username>
<p><input type=submit value=Login> <p><input type=submit value=Login>
</form> </form>

Loading…
Cancel
Save