diff -u D:\Dati\taxonomy_defaults_patch\original/taxonomy_defaults.admin.inc D:\Dati\taxonomy_defaults_patch\patch/taxonomy_defaults.admin.inc --- D:\Dati\taxonomy_defaults_patch\original/taxonomy_defaults.admin.inc 2010-04-02 13:16:19.696195100 +0200 +++ D:\Dati\taxonomy_defaults_patch\patch/taxonomy_defaults.admin.inc 2010-04-02 13:15:27.142063200 +0200 @@ -15,46 +15,48 @@ $vocabularies = taxonomy_get_vocabularies(); foreach (node_get_types() as $type => $name) { - $type_vocabularies = taxonomy_get_vocabularies($type); - // Loop over all vocabularies - foreach ($vocabularies as $vid => $vocab) { - $activevocab = array_key_exists($vid, $type_vocabularies); - - if ($activevocab) { - $form[$type][$vid]['hide_vocab'] = array( - '#type' => 'checkbox', - '#default_value' => !variable_get("taxdef_{$type}_{$vid}_visible", TRUE), - '#weight' => -16, - ); - $form[$type][$vid]['name'] = array('#value' => t($vocab->name)); - - // If the vocabulary stores tags, add an autocomplete field for it. - if ($vocab->tags) { - $stored_terms = variable_get("taxdef_{$type}_{$vid}", array()); - $stored_tags = array(); - - foreach ( $stored_terms as $tid ) { - $term = taxonomy_get_term($tid); - if ( $term ) - $stored_tags[] = $term->name; - } - $stored_tags = drupal_implode_tags($stored_tags); - $form[$type][$vid]['tags'] = array( - '#type' => 'textfield', - '#description' => "Begin typing", - '#default_value' => $stored_tags, - '#autocomplete_path' => 'taxonomy/autocomplete/'. $vocab->vid, - '#maxlength' => 255, + if (!($type == 'forum')) { + $type_vocabularies = taxonomy_get_vocabularies($type); + // Loop over all vocabularies + foreach ($vocabularies as $vid => $vocab) { + $activevocab = array_key_exists($vid, $type_vocabularies); + + if ($activevocab) { + $form[$type][$vid]['hide_vocab'] = array( + '#type' => 'checkbox', + '#default_value' => !variable_get("taxdef_{$type}_{$vid}_visible", TRUE), + '#weight' => -16, ); + $form[$type][$vid]['name'] = array('#value' => t($vocab->name)); + + // If the vocabulary stores tags, add an autocomplete field for it. + if ($vocab->tags) { + $stored_terms = variable_get("taxdef_{$type}_{$vid}", array()); + $stored_tags = array(); + + foreach ( $stored_terms as $tid ) { + $term = taxonomy_get_term($tid); + if ( $term ) + $stored_tags[] = $term->name; + } + $stored_tags = drupal_implode_tags($stored_tags); + $form[$type][$vid]['tags'] = array( + '#type' => 'textfield', + '#description' => "Begin typing", + '#default_value' => $stored_tags, + '#autocomplete_path' => 'taxonomy/autocomplete/'. $vocab->vid, + '#maxlength' => 255, + ); + } + // Other vocabularies get added as normal selectors. + else { + $form[$type][$vid]['select'] = taxonomy_form($vid, variable_get("taxdef_{$type}_{$vid}", 0)); + } } - // Other vocabularies get added as normal selectors. else { - $form[$type][$vid]['select'] = taxonomy_form($vid, variable_get("taxdef_{$type}_{$vid}", 0)); - } - } - else { - if (variable_get("taxdef_{$type}_{$vid}", FALSE)) { - drupal_set_message(t("Taxonomy Defaults were detected for the @vocab vocabulary on the @type content type, but @type is not selected in @vocab !settings. !details.", array('@vocab' => $vocab->name, '@type' => $type, '!settings' => l('settings','/admin/content/taxonomy/edit/vocabulary/'.$vid), '!details' => l('Explanation','http://drupal.org/node/559828#comment-2162950'))),"warning"); + if (variable_get("taxdef_{$type}_{$vid}", FALSE)) { + drupal_set_message(t("Taxonomy Defaults were detected for the @vocab vocabulary on the @type content type, but @type is not selected in @vocab !settings. !details.", array('@vocab' => $vocab->name, '@type' => $type, '!settings' => l('settings','/admin/content/taxonomy/edit/vocabulary/'.$vid), '!details' => l('Explanation','http://drupal.org/node/559828#comment-2162950'))),"warning"); + } } } } diff -u D:\Dati\taxonomy_defaults_patch\original/taxonomy_defaults.module D:\Dati\taxonomy_defaults_patch\patch/taxonomy_defaults.module --- D:\Dati\taxonomy_defaults_patch\original/taxonomy_defaults.module 2009-10-18 08:19:34.000000000 +0200 +++ D:\Dati\taxonomy_defaults_patch\patch/taxonomy_defaults.module 2010-04-02 12:55:08.615494100 +0200 @@ -96,7 +96,7 @@ } } } - else { + else if (!($node->type =='forum')) { if ($visible) { // Do not preselect terms on nodes that already have been edited if (!isset($node->nid)) {