Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
why would the title simply be empty? did i miss something?
<span title="" class="nolink">LinkName</span>
Comments
Comment #1
roderikTry the -dev version (as of may 12, 2015). This removes special_items_init(). This worked for me; may work for you too.
In my case, the empty title was caused by the combination of
menu_get_active_trail() builds menu items and caches them for the remainder of the request. However, if it's called from hook_init(), the include-file with the title callback is not loaded yet, your callback isn't found and the cached trail will have an empty title for the menu item.
drupal_get_title() will later use the already-cached trail from menu_get_active_trail(), and output the empty title.