How to change menu links items title programitically? I have created a menu name My Menu (machine name: my_menu ) with menu item My Nodes and My messages. Now I want alter My nodes and My messages link title. So the menu items should look like Nodes and Messages instead of My nodes and My Messages.

So I don't understand and also didn't find how can I alter the menu link title programmatically. i am trying to use hook_menu_alter(&amp;$items) and hook_menu_link_alter(&amp;$item), but it doesn't give any result. 

So can anyone please tell me how can I alter the menu link items title? 

Thanks in advance
Use theme_link function for altering your link markup. I have recently come across a scenario where I needed to change my account name to user name I did with the following code.

function THEMENAME_link($variables) {
  if ($variables['text'] == "My account") {
    $variables['text'] = $GLOBALS['user']-&gt;name;
  }

return '&lt;a href="' . check_plain(url($variables['path'], $variables['options'])) . '"' . drupal_attributes($variables['options']['attributes']) . '&gt;' . ($variables['options']['html'] ? $variables['text'] : check_plain($variables['text'])) . '&lt;/a&gt;';
}