summaryrefslogtreecommitdiff
path: root/docs/ref
diff options
context:
space:
mode:
authorJannis Leidel <jannis@leidel.info>2010-10-01 02:02:58 +0000
committerJannis Leidel <jannis@leidel.info>2010-10-01 02:02:58 +0000
commit392d992f8295f96632179e01e790465cc9c8d3ec (patch)
treebc1d6e3b0819f1b2a58a91d146fa6eb112d8396d /docs/ref
parenta64e96c227b36c701a86ded75d839b1cd2442713 (diff)
Fixed #7048 -- Added ClearableFileInput widget to clear file fields. Thanks for report and patch, jarrow and Carl Meyer.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@13968 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'docs/ref')
-rw-r--r--docs/ref/forms/fields.txt4
-rw-r--r--docs/ref/forms/widgets.txt8
2 files changed, 10 insertions, 2 deletions
diff --git a/docs/ref/forms/fields.txt b/docs/ref/forms/fields.txt
index 0dd9095a77..d2b1c303ed 100644
--- a/docs/ref/forms/fields.txt
+++ b/docs/ref/forms/fields.txt
@@ -507,7 +507,7 @@ given length.
.. class:: FileField(**kwargs)
- * Default widget: ``FileInput``
+ * Default widget: ``ClearableFileInput``
* Empty value: ``None``
* Normalizes to: An ``UploadedFile`` object that wraps the file content
and file name into a single object.
@@ -573,7 +573,7 @@ These control the range of values permitted in the field.
.. class:: ImageField(**kwargs)
- * Default widget: ``FileInput``
+ * Default widget: ``ClearableFileInput``
* Empty value: ``None``
* Normalizes to: An ``UploadedFile`` object that wraps the file content
and file name into a single object.
diff --git a/docs/ref/forms/widgets.txt b/docs/ref/forms/widgets.txt
index 05215d4d8e..c01a7368bd 100644
--- a/docs/ref/forms/widgets.txt
+++ b/docs/ref/forms/widgets.txt
@@ -46,6 +46,14 @@ commonly used groups of widgets:
File upload input: ``<input type='file' ...>``
+.. class:: ClearableFileInput
+
+ .. versionadded:: 1.3
+
+ File upload input: ``<input type='file' ...>``, with an additional checkbox
+ input to clear the field's value, if the field is not required and has
+ initial data.
+
.. class:: DateInput
.. versionadded:: 1.1