~ubuntu-branches/ubuntu/quantal/python-django/quantal

« back to all changes in this revision

Viewing changes to docs/ref/contrib/formtools/form-wizard.txt

  • Committer: Bazaar Package Importer
  • Author(s): Jamie Strandboge
  • Date: 2010-10-12 11:34:35 UTC
  • mfrom: (1.1.12 upstream) (29.1.1 maverick-security)
  • Revision ID: james.westby@ubuntu.com-20101012113435-yy57c8tx6g9anf3e
Tags: 1.2.3-1ubuntu0.1
* SECURITY UPDATE: XSS in CSRF protections. New upstream release
  - CVE-2010-3082
* debian/patches/01_disable_url_verify_regression_tests.diff:
  - updated to disable another test that fails without internet connection
  - patch based on work by Kai Kasurinen and Krzysztof Klimonda
* debian/control: don't Build-Depends on locales-all, which doesn't exist
  in maverick

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
.. _ref-contrib-formtools-form-wizard:
2
 
 
3
1
===========
4
2
Form wizard
5
3
===========
10
8
.. versionadded:: 1.0
11
9
 
12
10
Django comes with an optional "form wizard" application that splits
13
 
:ref:`forms <topics-forms-index>` across multiple Web pages. It maintains
 
11
:doc:`forms </topics/forms/index>` across multiple Web pages. It maintains
14
12
state in hashed HTML :samp:`<input type="hidden">` fields, and the data isn't
15
13
processed server-side until the final form is submitted.
16
14
 
65
63
 
66
64
The first step in creating a form wizard is to create the
67
65
:class:`~django.forms.Form` classes.  These should be standard
68
 
:class:`django.forms.Form` classes, covered in the :ref:`forms documentation
69
 
<topics-forms-index>`.  These classes can live anywhere in your codebase, but
 
66
:class:`django.forms.Form` classes, covered in the :doc:`forms documentation
 
67
</topics/forms/index>`.  These classes can live anywhere in your codebase, but
70
68
convention is to put them in a file called :file:`forms.py` in your
71
69
application.
72
70
 
189
187
Hooking the wizard into a URLconf
190
188
=================================
191
189
 
192
 
Finally, give your new :class:`FormWizard` object a URL in ``urls.py``. The
193
 
wizard takes a list of your :class:`~django.forms.Form` objects as arguments::
 
190
Finally, we need to specify which forms to use in the wizard, and then
 
191
deploy the new :class:`FormWizard` object a URL in ``urls.py``. The
 
192
wizard takes a list of your :class:`~django.forms.Form` objects as
 
193
arguments when you instantiate the Wizard::
194
194
 
195
195
    from django.conf.urls.defaults import *
196
196
    from mysite.testapp.forms import ContactForm1, ContactForm2, ContactWizard