function _xmlsitemap_set_breadcrumb in XML sitemap 7.2
Same name and namespace in other branches
- 6.2 xmlsitemap.module \_xmlsitemap_set_breadcrumb()
Workaround for missing breadcrumbs on callback and action paths.
@todo Remove when https://www.drupal.org/node/576290 is fixed.
4 calls to _xmlsitemap_set_breadcrumb()
- xmlsitemap_custom_delete_link_form in xmlsitemap_custom/
xmlsitemap_custom.admin.inc - Delete Link Form.
- xmlsitemap_custom_edit_link_form in xmlsitemap_custom/
xmlsitemap_custom.admin.inc - Edit Link Form.
- xmlsitemap_sitemap_delete_form in ./
xmlsitemap.admin.inc - Delete form.
- xmlsitemap_sitemap_edit_form in ./
xmlsitemap.admin.inc - Edit Form.
File
- ./
xmlsitemap.module, line 1675 - xmlsitemap XML sitemap
Code
function _xmlsitemap_set_breadcrumb($path = 'admin/config/search/xmlsitemap') {
$breadcrumb = array();
$path = explode('/', $path);
do {
$menu_path = implode('/', $path);
$menu_item = menu_get_item($menu_path);
array_unshift($breadcrumb, l($menu_item['title'], $menu_path));
} while (array_pop($path) && !empty($path));
array_unshift($breadcrumb, l(t('Home'), NULL));
drupal_set_breadcrumb($breadcrumb);
}