Drupal 6.15-16 (haven't looked at other versions).
Modules enabled: Taxonomy Menu (root module portion only)
I created three taxonomy menus, and with all settings being equal, one of them would not show up. The only difference between the three were the number of terms in each vocabulary, and the one that would not show up had ~80 terms, the other two far less. After a code and database review I came up with the following...
In the menu_links table, the link_path field is set to varchar(255). With the large number of taxonomy terms, this field was truncated. It's value is "taxonomy/term/123 456 789...". With so many terms, the field truncated the full term list, breaking the menu. I then changed the link_path field type from varchar(255) to longtext and now everything is working fine.
Comments
Comment #1
perandre commentedHouston, we have a solution (to #523910: taxonomy menu disappears on large vocabularies).
Comment #2
indytechcook commentedChanging the title to remind me to fix this problem and truncate the value before I send to menu_link_save
Comment #3
arlinsandbulte commentedNote: I marked #523910: taxonomy menu disappears on large vocabularies as a duplicate of this issue.
That may not be 100% correct, but the fix in this issue will likely solve most of the problems over there.
That issue does have a longer history and more discussion, but this issue has a fix outlined.
Comment #4
indytechcook commentedA fix is in version 2.6.
Comment #6
jvieille commentedThis issue is not solved in 2.8 - the database has still the link_path field set to varchar(255)
I was deadly hit today...
Thanks for the fix.
Comment #7
indytechcook commentedThe fix that was in basically breaks the link. If the url is truncated then the path will not be correct.
Updating the table a core table is also something I'm not willing to do in this module.
We need a better fix, I'm just not sure what it would be.
Comment #8
hass commented+
Comment #9
jvieille commentedWhy the hell does taxonomy menu has to pass every single term in a url?
Comment #10
indytechcook commentedThe URL is generated by the taxonomy module. NOT taxonomy menu.
Comment #11
jvieille commentedSuch an optional update of a core table should not induce any risk.
Basically, a 255 character limit for urls is non-sense. This might hit again somewhere else
Comment #12
indytechcook commentedjvielle,
As with most parts of Drupal, it's not that simple. Following Drupal schema API (http://drupal.org/node/159605) the varchar field type is limited to 255 characters. To change the number of characters could also require the type of field. You are welcome to change the add an update hook in your own custom module to modify the table using http://drupal.org/node/150215 and http://drupal.org/node/150223 as a guide.
Comment #13
interestingaftermath commentedsubscribe
Comment #14
roxflame commentedIf your terms are in a hierarchy and you havn't tagged any nodes with the parent items (ie you only have parent terms for structure).
Then if you have the "Hide empty terms" option on for that vocabulary, it'll hide (disable in menu tree) your parent terms, thus not showing any of the children either.
Either tag items to the parents, turn this option off, or re-enable the parent items in the menu you selected after your rebuild.
Comment #15
johnvMore explicit title.
An alternative solution might be #1668388: Use 'all' at the end of URL not working
Comment #16
dstolThe Drupal 6 version is no longer supported