Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Fixed #12601: Documented the slug field in the forms module.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@12673 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 926bf195e007cb4f97e6ddc4bd963cb5a8d48288 1 parent 795e323
James Bennett authored March 03, 2010

Showing 1 changed file with 15 additions and 0 deletions. Show diff stats Hide diff stats

  1. 15  docs/ref/forms/fields.txt
15  docs/ref/forms/fields.txt
@@ -659,6 +659,21 @@ compatibility. The preferred way to provide an error message is to use the
659 659
 ``error_messages`` argument, passing a dictionary with ``'invalid'`` as a key
660 660
 and the error message as the value.
661 661
 
  662
+``SlugField``
  663
+~~~~~~~~~~~~~
  664
+
  665
+.. class:: SlugField(**kwargs)
  666
+
  667
+   * Default widget: ``TextInput``
  668
+   * Empty value: ``''`` (an empty string)
  669
+   * Normalizes to: A Unicode object.
  670
+   * Validates that the given value contains only letters, numbers and
  671
+     hyphens.
  672
+   * Error messages: ``required``, ``invalid``
  673
+
  674
+This field is intended for use in representing a model
  675
+:class:`~django.db.models.SlugField` in forms.
  676
+
662 677
 ``TimeField``
663 678
 ~~~~~~~~~~~~~
664 679
 

0 notes on commit 926bf19

Please sign in to comment.
Something went wrong with that request. Please try again.