Hi there,
following your validation documentation here: https://docs.metabox.io/validation/ I used your suggested methodology to add disallowed file type validation on a 'type'=> 'file' custom field like this:
'fields' => [
[
'name' => 'Uploaded Files',
'id' => 'my_files',
'type' => 'file',
],
],
'validation' => [
'rules' => [
'_file_my_files[]' => [
'extension' => 'pdf',
],
],
'messages' => [
'_file_my_files[]' => [
'extension' => 'file extension not allowed',
],
],
],
Strictly following the validation page instructions - On my MB Frontend Form, using this method, I do not see any validation feedback on my custom field when the file type is PDF? Can you confirm this works for you at your end on a frontend form?
Cheers