$forms->form() method

Convert given value to FormBuilderForm if it isn’t already

Throws FormBuilderException if given value cannot be converted to a FormBuilderForm

Usage

// basic usage
$formBuilderForm = $forms->form($form);

// usage with all arguments
$formBuilderForm = $forms->form($form, bool $throw = true);

Arguments

NameType(s)Description
formFormBuilderForm, string, int
throw (optional)bool

Throw exception if form not found? If false, method returns false rather than throwing Exception (default=true)

Return value

Exceptions

Method can throw exceptions on error:

  • FormBuilderException


$forms methods and properties

API reference based on ProcessWire core version 3.0.244

I just love the easy and intuitive ProcessWire API. ProcessWire rocks!” —Jens Martsch, Web developer