Drupal: collapse CCK Fields in edit content pages?
can I collapse the field in my edit-content page in Drupal ?
For example, at the bottom of the page Revision Information, URL Path Settings, Authoring Information etc are collapsed.
I would like to have this functi开发者_运维技巧onality for the CCK Fields as well.
thanks
You can do this with hook_form_alter
by putting the fields into a fieldset the you make collapsible.
You can also use the CCK Fieldgroup module to create a fieldgroup in the same interface you create new fields. Go to the fieldgroup settings page to make it collapsed by default. Then drag-n-drop fields to be under a given fieldgroup.
Fieldgroup is part of the CCK project, just turn it on in the modules page.
Using hook_form_alter()
is a cleaner solution but technically a bit more difficult.
精彩评论