Wednesday, 25 February 2009

Filling one field with the value of another field

I am using the Biblio module for managing bibliographic references in a Drupal site and I found a problem when using views: these 2 modules are not integrated and when I require a one of its fields in a view I get code as plain text. Because of the first rush I used a trick to overcome the problem: making another field with CCK. Everytime an editor (myself) fill the form of a biblio, I need to copy an paste the content of 2 fields in another 2 extra (hidden) fields. I'm planning to make this available for a first bunch of end-users and obviously, this has to change.

One solution could be to remove this 2 extra hidden fields from the form and to fill them automatically using the default value field and a more consistent trick. Some hints to explore: http://drupal.org/node/260451