DEPRECATION WARNING

This documentation is not using the current rendering mechanism and is probably outdated. The extension maintainer should switch to the new system. Details on how to use the rendering mechanism can be found here.

Form

Replaces the basic form ViewHelper from Fluid (<f:form>).

It works the same way as the basic ViewHelper, expect that the argument name is required (see below).

Important

You must use this ViewHelper when integrating a form using FormZ.

Arguments

Argument Description
* name Must be exactly the name of the variable in the controller action on which the form is bound (see example below).
You can use all available arguments from the basic Fluid ViewHelper.

Example

{namespace fz=Romm\Formz\ViewHelpers}

<fz:form action="submitForm" name="myForm">
    ...
</fz:form>

The form below is bound to the action submitForm. If we check the action in the controller PHP class:

public function submitFormAction(MyForm $myForm)
{
    // ...
}

The name of the variable is $myForm: the parameter name of the ViewHelper must be the same.

For the rest, nothing changes, you can use all features of a basic Fluid form.