API — JavaScript

To allow JavaScript more advanced behaviours than those available by default with FormZ, you can use this API.

To fetch a form, you have to use a code similar to this one:

Fz.Form.get('myFormName', function(form) {
    // Whatever...
});

The name of the form must match the name you gave to the ViewHelper in your template (see “Form”). You then have access to the variable form, which allows you to manipulate whatever you need.

You can then manipulate: