Remove a term from content
adpo - September 15, 2009 - 09:39
| Project: | Rules |
| Version: | 6.x-1.x-dev |
| Component: | Rules Engine |
| Category: | support request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
Description
Remove a term from content is not working. Not sure why.
Tested with: 6.x-1.1 and 6.x-1.x-dev
Tested with patch: [456328#comment-1639754]
My workflow is:
Load a vocabulary
Load a term
Remove a term from content
PS. I can assign term to content with no problem:
Load a vocabulary
Load a term
Assign a term to content

#1
Does not seem to be Rules Forms related.
#2
Indeed, It is not about Rules Forms but Triggered rules. Does anyone had a similar issue with rules and found an answer? Thank you for reply.
#3
what I did was make a call to:
taxonomy_node_delete(..)
in function rules_action_taxonomy_term_remove_from_content(..) in taxonomy.rules.inc instead of all the things that the function is originally doing, and that seems to fix the problem.
hope this helps.
#4
Thank you I will try
#5
Hi scholesy ,
I have the same problem,
How did you make this call (taxonomy_node_delete(..))
Can you provide a more detailed code?
#6
OK, what I did was just replace what was inside function rules_action_taxonomy_term_remove_from_content, so the function now is simply:
/**
* Action: Remove a term from content.
*/
function rules_action_taxonomy_term_remove_from_content($node, $taxonomy_term, $settings) {
taxonomy_node_delete($node);
}
Hope this helps.