Typically, a data object will be a Record object returned from a Model, but you can
define your own custom objects as well. For more information on custom data objects, see
lithium\template\helper\Form::$_binding.
public create ( mixed $bindings = null, array $options = [] ) : string | ||
$bindings | mixed | List of objects, or the object to bind the form to. This is usually an instance of `Record` or `Document`, or some other class that extends `lithium\data\Entity`. |
$options | array | Other parameters for creating the form. Available options are: - `'url'` _mixed_: A string URL or URL array parameters defining where in the application the form should be submitted to. - `'action'` _string_: This is a shortcut to be used if you wish to only specify the name of the action to submit to, and use the default URL parameters (i.e. the current controller, etc.) for generating the remainder of the URL. Ignored if the `'url'` key is set. - `'type'` _string_: Currently the only valid option is `'file'`. Set this if the form will be used for file uploads. - `'method'` _string_: Represents the HTTP method with which the form will be submitted (`'get'`, `'post'`, `'put'` or `'delete'`). If `'put'` or `'delete'`, the request method is simulated using a hidden input field. |
return | string | Returns a ` |