Getting started

You need to have a version of Albatross which has the Albatross Forms support included (or have installed it by hand yourself). You can quickly test whether it is present by running:

$ python
Python 2.6.1 (r261:67515, Jul  7 2009, 23:51:51)
[GCC 4.2.1 (Apple Inc. build 5646)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from albatross.ext import form
>>>

If it's missing, you'll see an import error.

Adding the {{{alx-form}}} tag

In each Albatross application, there is a point at which an instance of App (or a subclass thereof) is created, usually in app.py or app.cgi or wherever the main entry point of the application is. This needs instance needs to be told about the new tag. That's done in code that usually looks something like this:

   1 from albatross.ext import form
   2 ...
   3 
   4 if __name__ == '__main__':
   5     app = App()
   6     for tag_class in form.tag_classes:
   7         app.register_tagclasses(tag_class)
   8     app.run(Request())