[development] D7: Getting attached files from nid and field name
    Fabio Varesano 
    fabio.varesano at gmail.com
       
    Thu Jul  7 08:08:36 UTC 2011
    
    
  
Hi everyone,
In Drupal 7.x, given a nid and a file field name, I'm trying to get
the files (as fids or file objects) which have been uploaded as file
attachments to that node.
Drupal will populate $node->{$field_name} only when there are files
set as "displayed" but I need to do this for all the files of that
field, no matters how their display setting is.
I've spent quite some time investigating into this but the new d7 file
api looks pretty obscure from a documentation and code point of view.
IMHO, too much "drupal magic" happening there for a fast understanding.
Any pointer to good documentation and/or suggestion on the solution
greatly appreciated.
Thanks,
Fabio Varesano
    
    
More information about the development
mailing list