At this moment using parent_php_code you can provide only one parent but there are situations when you have hierarchy split by different controls and one depend on another with multiple selected items. I've provided a patch to allow user specifying different parents in "parent_php_code".
| Comment | File | Size | Author |
|---|---|---|---|
| content_taxonomy.module-multiple-parents.patch | 2.95 KB | desunit |
Comments
Comment #1
Bilmar commentedThis patch fails with the current 6.x-1.x-dev release. Is this patch to allow terms with multiple parents to be shown in
Advanced settings for hierarchical vocabularies; Parent Term:? I am experiencing this problem.
Tokyo
-Japan Rail
--Line A
---Station 1
---Station 2
--Line B
---Line 3
-Line A<= if name of this line is after 'Japan Rail' in the alphabet, this line does not show as it already appeared above(!)
--Station 1
--Station 2
etc
ERROR from patching:
(Stripping trailing CRs from patch.)
patching file content_taxonomy.module
Hunk #1 FAILED at 257.
Hunk #2 FAILED at 289.
2 out of 2 hunks FAILED -- saving rejects to file content_taxonomy.module.rej
Could this patch please be brought up to the latest dev?
Comment #2
YK85 commentedsubscribing
Comment #3
Maguar commentedsubscribing!
Comment #4
summit commentedSubscribing, greetings, Martijn
Comment #5
robby.smith commentedconfirmed terms under multiple parents are not shown more than once..making it difficult to select parent term for hierarchy of content taxonomy field.
subscribing.
Comment #6
robby.smith commentedI was wondering if there has been any progress/development in this area?
Thanks!
Comment #7
peterpoe commentedTerms with multiple parents are not repeated because they have the same term id, so they are overwritten.
You can change the building of the array from: $options[$term->tid] to something like $options["$parent][$term->tid"] but I'm not sure this is a solution, since the values of the form will not reflect the term ids anymore!
Comment #8
robby.smith commentedDoes the attached patch (that no longer is up-to-date) use your suggested method or a different method? Also, as an example Taxonomy Manager module is able to successfully display all the field in the right hierarchy for fields with multiple parents.
I apologize that I know zip about programming but I hope I can help in anyway to get this issue resolved.
I would really appreciate your support!
Comment #9
YK85 commentedWould anyone be able to help by creating a patch to fix this issue?
I believe this is a big issue as terms with multiple parents are not shown after their first occurence in the content taxonomy field setting of parent term to use.
Thank you!
Comment #10
robby.smith commentedkindly bumping - would anyone be able to help?
Comment #11
magnus commentedComment #12
Andrew Gorokhovets commentedsubscribing
Comment #13
Roze-1 commentedsubscribing !
Comment #14
Roze-1 commentedHirarchical Select + Content Taxonomy can be used to create multiple parents.