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.
If "Generic file" formatter is used and a file has been given a 'description', it should display the 'desciption' instead of the file name. This was working on 3.3 and earlier.
Image attached displays a view that lists 3 files. All 3 have been given descriptions. But the Generic field is displaying the file name instead of the description.
Comments
Comment #1
quicksketchCould you try out the patch in #841212: warning: array_merge() [function.array-merge]: Argument #1 is not an array in..../filefield_field.inc on line 292.? The "data" column needs to be unserialized.
Comment #2
harcher CreditAttribution: harcher commentedI did this already and applied it to 3.6:
http://drupal.org/node/841212#comment-3150628
Looking at the file filefield/filefield_formatter.inc, I noticed that the $file['data'] doesn't have the variable 'description'. This is why the 'if' statement on line 138 executes and uses $file['filename'] as the link text:
I did a firep to inspect the array $file on 3.3 and 3.6. Notice that on 3.3 you have a 'description' variable but 3.6 doesn't.
Comment #3
quicksketch#12 in #841212 should now fix this problem too. I'm leaving this issue open but moving to postponed, since all these issues have to do with unserializing the "data" column.
See #841212-12: warning: array_merge() [function.array-merge]: Argument #1 is not an array in..../filefield_field.inc on line 292.
Comment #4
quicksketchVersion 3.7 is now available. Sorry for the troubles everyone.