We use the "image URL" field via profile to allow members to upload their organization logo. We would like to limit the file size a user can upload. Are there any options for us? Thank you!

  • 1
    Are you using Drupal, Joomla or WP?
    – Coleman
    Oct 14, 2017 at 12:38
  • We are using WP and CiviCRM 4.7.14. Oct 15, 2017 at 18:36
  • Are you uploading other files that will be larger than the image file size?
    – Sleewok
    Oct 17, 2017 at 20:37

1 Answer 1


You should be able to implement a hook via PHP to validate the profile when it is submitted: https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_processProfile/.

Someone else may want to chime in. I'm not sure if you can use form hooks with profiles. Otherwise you may check this: https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_validateForm/

You can then use PHP to validate the file size: Check this thread (https://stackoverflow.com/questions/9153224/how-to-limit-file-upload-type-file-size-in-php).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.