The v3 QA framework is replaced by v4's Forms framework. Forms and questions are now content objects, which means:
New features that are made possible by this approach:
Other new features that have also been added:
Note that, as content objects, forms do not utilize service pages any more. However, forms effectively serve as their own service page. To embed a form into a page, place the form content object under that page, and embed it into the page content using < !--content(form_name)-->
. Submitting that form effectively directs you to /cgi/ex.cgi/page_name/form_name
, which allows you to customize the layout of the form response.
As a developer, the primary change to consider is that forms are not remote objects that are referenced through a qa_form_id
, but are content objects that can be embedded right in the object you are working on. For example a registration fee can contain its own form as sub-content. Or a membership type can contain a sign-up form as sub-content. To check for the existence of such a form, do this:
$registration_form = $fee->my_content("registration_form");
$registration_form
will now be the form object itself, if one exists.