Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Please tell me Is it Possible to add custom validation to file_cck ? My need is when i upload files, i want to confirm whether the uploaded file is with correct mime type ? (now a html file with pdf extension is allowed to upload)
Comments
Comment #1
johanneshahn CreditAttribution: johanneshahn commentedthere is a restriction Modul for that
But i know that File_cck does not use the allowed mime in the field settings
Comment #2
johanneshahn CreditAttribution: johanneshahn commentedone up to dev
Comment #3
kdineshbe CreditAttribution: kdineshbe commentedS you can add validation to file_cck. To check file extensions, u can use finfo_file (). It is inbuilt with php 5.3
Comment #4
gobinathmClosing the issue. It was inactive for a long time & it's related to a Drupal Version which is not supported anymore