public function __construct($name = null, $action = null, $method = 'post', $useToken = true, $useGlobalError = true)
{
if (BackendModel::getContainer()->has('url')) {
$this->URL = BackendModel::getContainer()->get('url');
}
if (BackendModel::getContainer()->has('header')) {
$this->header = BackendModel::getContainer()->get('header');
}
$this->useGlobalError = (bool) $useGlobalError;
// build a name if there wasn't one provided
$name = $name === null ? \SpoonFilter::toCamelCase($this->URL->getModule() . '_' . $this->URL->getAction(), '_', true) : (string) $name;
// build the action if it wasn't provided
$action = $action === null ? '/' . $this->URL->getQueryString() : (string) $action;
// call the real form-class
parent::__construct($name, $action, $method, $useToken);
// add default classes
$this->setParameter('id', $name);
$this->setParameter('class', 'fork-form submitWithLink');
}