Skip to content

Instantly share code, notes, and snippets.

@ahaubold
Created June 10, 2015 08:03
Show Gist options
  • Save ahaubold/abacbfdee65a5d2428b8 to your computer and use it in GitHub Desktop.
Save ahaubold/abacbfdee65a5d2428b8 to your computer and use it in GitHub Desktop.
Property validation in TYPO3/extbase
/*
* @validate \Typovision\Simpleblog\Validation\Validator\WordValidator(max=3)
* @validate Typovision.Simpleblog:Word2(max=5)
*/
//Im Validator unter Classes ... \[Vendor]\[Ext]\Validation\Validator\WordValidator
// !addError entscheidet darüber, ob valide oder nicht (nicht return FALSE)
$this->addError('Verringern Sie die Anzahl der Worte. Es sind maximal '.$max.' erlaubt!', 1383400016);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment