There is no checkbox "Allow users to select files from IMCE File Browser for this field" on Commerce File fields. It seems the Commerce File fields are just like normal File Fields with some added functionality... Is there any way to add this?

Thanks!

Comments

ufku’s picture

You can alter the supported widget types by defining hook_imce_filefield_supported_widgets_alter

function MYMODULE_imce_filefield_supported_widgets_alter(&$widgets) {
  // $widgets is originally defined as array('file_generic', 'image_image').
  $widgets[] = 'CUSTOM_WIDGET_TYPE';
}

The hook can also be defined by your theme in case it is used for node editing pages.

bohemier’s picture

Thanks ufku! I have posted a feature request in the commerce file issue queue here http://drupal.org/node/1962640 with the proper code...

Works great for me!

ufku’s picture

Status: Active » Closed (fixed)