diff options
| author | Marc Tamlyn <marc.tamlyn@gmail.com> | 2013-05-19 05:26:13 -0700 |
|---|---|---|
| committer | Marc Tamlyn <marc.tamlyn@gmail.com> | 2013-05-19 05:26:13 -0700 |
| commit | c6855e8a704a8fadee8fc0eefcd99c5dc5372ab2 (patch) | |
| tree | 62cecfa131e9bd5b08caaaccc823ac2b75d9d932 /docs/ref/forms/widgets.txt | |
| parent | c28b79580493f4bf5df9bea88a5c6bddfe27a6d6 (diff) | |
| parent | 1fe587d80bfcf062a94252fb532c8ac035c833b9 (diff) | |
Merge pull request #1162 from sspross/patch-docs
Add needed Imports to the Documentation, Part II
Diffstat (limited to 'docs/ref/forms/widgets.txt')
| -rw-r--r-- | docs/ref/forms/widgets.txt | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/docs/ref/forms/widgets.txt b/docs/ref/forms/widgets.txt index 678f2e6949..0f6917d44c 100644 --- a/docs/ref/forms/widgets.txt +++ b/docs/ref/forms/widgets.txt @@ -201,6 +201,7 @@ foundation for custom widgets. .. code-block:: python + >>> from django import forms >>> name = forms.TextInput(attrs={'size': 10, 'title': 'Your name',}) >>> name.render('name', 'A name') u'<input title="Your name" type="text" name="name" value="A name" size="10" />' @@ -249,6 +250,8 @@ foundation for custom widgets. :class:`~datetime.datetime` value into a list with date and time split into two separate values:: + from django.forms import MultiWidget + class SplitDateTimeWidget(MultiWidget): # ... |
