function FileItem::getUploadValidators
Same name in other branches
- 9 core/modules/file/src/Plugin/Field/FieldType/FileItem.php \Drupal\file\Plugin\Field\FieldType\FileItem::getUploadValidators()
- 8.9.x core/modules/file/src/Plugin/Field/FieldType/FileItem.php \Drupal\file\Plugin\Field\FieldType\FileItem::getUploadValidators()
- 11.x core/modules/file/src/Plugin/Field/FieldType/FileItem.php \Drupal\file\Plugin\Field\FieldType\FileItem::getUploadValidators()
Retrieves the upload validators for a file field.
Return value
array An array suitable for passing to file_save_upload() or the file field element's '#upload_validators' property.
1 call to FileItem::getUploadValidators()
- ImageItem::defaultImageForm in core/
modules/ image/ src/ Plugin/ Field/ FieldType/ ImageItem.php - Builds the default_image details element.
File
-
core/
modules/ file/ src/ Plugin/ Field/ FieldType/ FileItem.php, line 347
Class
- FileItem
- Plugin implementation of the 'file' field type.
Namespace
Drupal\file\Plugin\Field\FieldTypeCode
public function getUploadValidators() {
return $this->getFileUploadValidators($this->getSettings());
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.