FluidTYPO3\Flux\Form::setId PHP Method

setId() public method

public setId ( string $id ) : FluidTYPO3\Flux\Form\FormInterface
$id string
return FluidTYPO3\Flux\Form\FormInterface
    public function setId($id)
    {
        $allowed = 'a-z0-9_';
        $pattern = '/[^' . $allowed . ']+/i';
        if (preg_match($pattern, $id)) {
            $this->getConfigurationService()->message('Flux FlexForm with id "' . $id . '" uses invalid characters in the ID; valid characters
				are: "' . $allowed . '" and the pattern used for matching is "' . $pattern . '". This bad ID name will prevent
				you from utilising some features, fx automatic LLL reference building, but is not fatal', GeneralUtility::SYSLOG_SEVERITY_NOTICE);
        }
        $this->id = $id;
        if (TRUE === empty($this->name)) {
            $this->name = $id;
        }
        return $this;
    }