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.
When I enable the File Entity and Media modules, then navigate to the Content >> Files page, I get a whitscreen. Likewise, the media browser is giving an error when I try to add Media to a node:
The website encountered an unexpected error. Please try again later.
The error_log file contains the following warnings:
[warn] mod_fcgid: stderr: PHP Fatal error: Unsupported operand types in .../file_entity/file_entity.admin.inc on line 28, referer: http://example.com/admin/modules?filter=media&enabled=1&disabled=1&required=1&unavailable=1
[warn] mod_fcgid: stderr: PHP Fatal error: Unsupported operand types in .../file_entity/file_entity.admin.inc on line 28
Comments
Comment #1
brylie CreditAttribution: brylie commentedComment #2
brylie CreditAttribution: brylie commentedUsing drush returns an additional error:
The media module directory is not on the include path.
Comment #3
Devin Carlson CreditAttribution: Devin Carlson commentedIt sounds like you've got a mix of files from Media 1.x and Media + File Entity 2.x as there is no file_entity folder in media/ with Media 7.x-2.x.
I'd suggest disabling and uninstalling Media and File Entity, deleting both folders and installing them from scratch. You may also need to manually remove any leftover tables in the database if the modules don't uninstall cleanly.