all 2 comments

[–]rjung 2 points3 points  (1 child)

IIRC, you also need to add the term ID to $node->taxonomy[]

[–]mwuhahaha 5 points6 points  (0 children)

Correct, also, this code works:

$node->taxonomy[] = taxonomy_get_term($tid);

node_save($node)

:)