Programatically load title of a views page by its machine name I would like to use the current title of a very specific views page in another template. Instead of just manually copying it and in order to stay flexible and always up to date, I would like to programatically load and insert it.

If my views page has machine name views_page, how do I programatically load its current title into a string?
Any of these should work:

Load the View and get the display title:

$view = views_get_view('views_page');
print $view-&gt;display['page_1']-&gt;display_options['title'];


Note: Change 'page_1' to the name of your display.


You can also get the page title from the path:

$item = menu_get_item(drupal_get_normal_path('path/to/page'));
print $item['title'];