The used Taxonomy ID while creation of forum-topic is hardcoded - should be variable

discussthis.module Line 409:

  $values['taxonomy'][1] = $tid;

the one should be the corresponding vocabulary-id for forum-vocab.

CommentFileSizeAuthor
#3 281092.patch851 bytesspiderman

Comments

EgonO’s picture

the corresponding vocab id is stored in the "vocabulary" table with the "module" field data "forum"

hope this helps

EgonO’s picture

me again ;)

the function taxonomy_get_vocabularies should be helpfull

spiderman’s picture

Assigned: Unassigned » spiderman
StatusFileSize
new851 bytes

Good catch! Attached is a patch to fix this by grabbing the forum_nav_vocabulary variable which forum.module sets up to determine which vocabulary ID should be used. Note this patch is against the latest CVS revision of the module (1.7)

spiderman’s picture

Status: Active » Needs review
spiderman’s picture

I just realized I hadn't properly committed my most recent changes to the correct branch, so the development snapshot tarball wasn't being updated properly. I've just committed this patch, along with the other recent HEAD revision commits to DRUPAL-5, so a fresh tarball should be up shortly.

Meantime EgonO, if you have a chance to test this patch and confirm that it works properly for you, I'd be glad to know it works for more than just me :)

EgonO’s picture

i'll try this patch later this evening, reporting you my experiences with it.

EgonO’s picture

Parse error: syntax error, unexpected T_VARIABLE in /var/www/htdocs/common/drupal-5.8/sites/all/modules/discussthis/discussthis.module on line 488

it's just the missing ";" after

$forum_vid = variable_get('forum_nav_vocabulary', 1)

the rest seems to work.

spiderman’s picture

Status: Needs review » Fixed

Yes, I goofed on the original patch, and committed a proper fix for this later on yesterday- if you download the latest -dev snapshot, you should be fine :)

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.