Index: modules/forum.module =================================================================== RCS file: /cvs/drupal/drupal/modules/forum.module,v retrieving revision 1.322 diff -u -r1.322 forum.module --- modules/forum.module 27 Mar 2006 18:02:48 -0000 1.322 +++ modules/forum.module 30 Mar 2006 23:21:51 -0000 @@ -203,6 +203,29 @@ } /** + * Implementation of hook_form_alter(). + */ +function forum_form_alter($form_id, &$form) { + // hide critical options from forum vocabulary + if ($form_id == 'taxonomy_form_vocabulary') { + + if ($form['vid']['#value'] == _forum_get_vid()) { + $form['help_forum_vocab'] = array( + '#value' => t('This is the designated forum vocabulary. Some of the normal vocabulary options have been removed.'), + '#weight' => -1, + ); + $form['hierarchy'] = array('#type' => 'hidden', '#value' => 1); + unset($form['relations']); + unset($form['tags']); + unset($form['multiple']); + $form['required'] = array('#type' => 'hidden', '#value' => 1); + } + //hide the forum content type from everything + unset($form['nodes']['#options']['forum']); + } +} + +/** * Implementation of hook_load(). */ function forum_load($node) {