function _manualcrop_supported_file in Manual Crop 7
Determine if a file supports cropping.
Parameters
$file: The file object.
Return value
TRUE if the file support cropping, FALSE otherwise.
1 call to _manualcrop_supported_file()
- manualcrop_croptool_process in ./
manualcrop.helpers.inc - Add a croptool to the form element. This extends the FAPI widget or simply adds a new form item to enable cropping in a regular form.
File
- ./
manualcrop.helpers.inc, line 1024 - Helper functions for the Manual Crop module.
Code
function _manualcrop_supported_file($file) {
if (empty($file->filemime)) {
return FALSE;
}
return strpos($file->filemime, 'image') === 0;
}