Before we start writing our new application, we'll need to create a skeleton again. We can create it using the following commands:
$ catalyst.pl AddressBook $ cd AddressBook/
We'll also need two more CPAN modules for this chapter. These can be installed from CPAN using the following command:
$ cpan Catalyst::Controller::FormBuilder Catalyst::Controller::BindLex
Note
This should really use FormHandler
, which is a Moose-based form handling framework that allows one to use nice object-oriented classes. FormHandler
is actively maintained while FormBuilder
hasn't been updated since 2007. BindLex
has also been deprecated for a while, I think even by its author.
The previous command will ensure that the latest version of each module is installed on your system. After installing the modules, we'll add a special Template Toolkit View called TTSite
to our application, using the following command:
$ perl script/addressbook_create.pl view HTML TTSite
TTSite
will automatically generate...