When using taxonomy menu to generate a suckerfish menu, the "a title='.....'" part of the generated menu item tag becomes a huge nuisance preventing proper navigation. To suppress this I have commented out lines 539, 540 of taxonomy_menu.module:

  $link = array(
    'link_title' => t($item['name']),
    'menu_name' => $item['menu_name'],
    'plid' => $plid,
    //'options' => array('attributes' => array('title' => t(trim($item['description'])
    //  ? $item['description'] : $item['name']))),
    'weight' => $weight,
    'module' => 'taxonomy_menu',
    'expanded' => $expanded,
    'link_path' => $path,
  );

Since this makes it nearly unusable in this specific circumstance, it would be fantastic to add one option, probably defaulting to "off" to suppress the output of title tags on menus.

Drupal core has set the precedent for suppressing title by default:
http://drupal.org/node/155312
http://drupal.org/node/547206

Comments

mattsteven’s picture

Here's a patch to suppress it in case anyone else has this problem. An admin menu option would be more helpful, but this will get me by until that's added to main.

diff -Naur taxonomy_menu/taxonomy_menu.module taxonomy_menu.old/taxonomy_menu.module
--- taxonomy_menu.old/taxonomy_menu.module	2010-05-03 12:00:06.000000000 -0500
+++ taxonomy_menu/taxonomy_menu.module	2010-01-21 19:47:02.000000000 -0600
@@ -517,8 +517,8 @@
     'link_title' => t($item['name']),
     'menu_name' => $item['menu_name'],
     'plid' => $plid,
-    'options' => array('attributes' => array('title' => t(trim($item['description'])
-      ? $item['description'] : $item['name']))),
+//    'options' => array('attributes' => array('title' => t(trim($item['description'])
+//      ? $item['description'] : $item['name']))),
     'weight' => $weight,
     'module' => 'taxonomy_menu',
     'expanded' => variable_get('taxonomy_menu_expanded_'. $item['vid'], TRUE),
dboulet’s picture

Status: Active » Closed (duplicate)

Seems to be a duplicate of #372324: Ability to turn off description.

maximpodorov’s picture

Version: 6.x-1.x-dev » 7.x-1.x-dev
Status: Closed (duplicate) » Active

This is not a duplicate of turning off descriptions. I suggest to apply this patch (for 7.x-1.x-dev) to support the requested feature:

--- taxonomy_menu.module.orig   2012-09-28 16:43:53.000000000 +0400
+++ taxonomy_menu.module        2012-10-11 01:18:53.459136571 +0400
@@ -635,8 +635,9 @@
     'link_title' => $item['name'],
     'menu_name' => $item['menu_name'],
     'plid' => $plid,
-    'options' => array('attributes' => array('title' => trim($item['description'])
-      ? $item['description'] : $item['name'])),
+    'options' => (variable_get(_taxonomy_menu_build_variable('display_title', $item['vid']), TRUE)) ?
+      array('attributes' => array('title' => trim($item['description']) ? $item['description'] : $item['name'])) :
+      array(),
     'weight' => $item['weight'],
     'module' => 'taxonomy_menu',
     'expanded' => variable_get(_taxonomy_menu_build_variable('expanded', $item['vid']), TRUE),
@@ -1090,6 +1091,12 @@
     'default' => FALSE,
   );
 
+  $options['display_title'] = array(
+    '#title' => t('Display menu item popup titles'),
+    '#description' => t('Display the popup titles for the term menu items.'),
+    'default' => TRUE,
+  );
+
   $options['term_item_description'] = array(
     '#title' => t('Add description for terms'),
     '#description' => t('Add the term description to the term menu item.'),
dstol’s picture

Version: 7.x-1.x-dev » 7.x-2.x-dev
Status: Active » Needs work

Let's address this in 7.x-2.x

maximpodorov’s picture

I'd recommend to add this patch to 7.x-1.x also, since it doesn't change and break anything (default variable value makes the module not to change it's behavior).

hles’s picture

Status: Needs work » Fixed

Fixed with Commit b4dde83 in 7.x-2.x. Making this one as fixed as we won't add any new feature in 7x-1.x.

Status: Fixed » Closed (fixed)

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