lithium\template\helper\Form::__call PHP Method

__call() public method

embed:lithium\tests\cases\template\helper\FormTest::testCustomInputTypes(1-2)
public __call ( string $type, array $params = [] ) : string
$type string The method called, which represents the `type` attribute of the `` tag.
$params array An array of method parameters passed to the method call. The first element should be the name of the input field, and the second should be an array of element attributes.
return string Returns an `` tag of the type specified in `$type`.
    public function __call($type, array $params = array())
    {
        $params += array(null, array());
        list($name, $options) = $params;
        list($name, $options, $template) = $this->_defaults($type, $name, $options);
        $template = $this->_context->strings($template) ? $template : 'input';
        return $this->_render($type, $template, compact('type', 'name', 'options', 'value'));
    }