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.
Apache Solr Attachments module gives you the ability to search the contents of files. Would it be possible to diff attachment contents if we could extract the content of the attachments?
Comments
Comment #1
Alan D. CreditAttribution: Alan D. commentedYes.
At a guess, you can use the two alter calls to populate an additional item in the row with content:
As long as the files are fairly small, you can just add on the contents as another value item ($old_values is just an unindexed array from memory). Or split the file based on its line ending if really large, adding multiple value items.
Or implement your own hook_entity_diff() to create a completely new field to insert into the Diff output.
Comment #2
Alan D. CreditAttribution: Alan D. commented