Closed jzaplet closed 6 years ago
Nette/Forms supports PATTERN RULE for $form->addUpload(), but live-form-validation not.
$form->addUpload()
$form->addUpload('file') ->setRequired(FALSE) ->addRule(Form::PATTERN, 'Image must have extension (.jpg or .png).', '.*\.(png|jpg)');
And it also works with $form->addMultiUpload(), but there we're waiting for merge PR (https://github.com/nette/forms/pull/192).
$form->addMultiUpload()
Thank you.
Nette/Forms supports PATTERN RULE for
$form->addUpload()
, but live-form-validation not.And it also works with
$form->addMultiUpload()
, but there we're waiting for merge PR (https://github.com/nette/forms/pull/192).