Commit 6f178ad6 authored by Dries's avatar Dries

- Patch #176748 by pwolanin, Rob Loach: fixed broken breadcrumbs.

parent 2a1e980c
......@@ -1445,7 +1445,8 @@ function node_menu() {
);
}
$items['node/%node'] = array(
'title' => 'View',
'title callback' => 'node_page_title',
'title arguments' => array(1),
'page callback' => 'node_page_view',
'page arguments' => array(1),
'access callback' => 'node_access',
......@@ -1514,6 +1515,13 @@ function node_menu() {
return $items;
}
/**
* Title callback.
*/
function node_page_title($node) {
return $node->title;
}
function node_init() {
drupal_add_css(drupal_get_path('module', 'node') .'/node.css');
}
......
......@@ -11,7 +11,6 @@
* Menu callback; presents the node editing form, or redirects to delete confirmation.
*/
function node_page_edit($node) {
drupal_set_title(t('Edit %title', array('%title' => $node->title)));
return drupal_get_form($node->type .'_node_form', $node);
}
......@@ -401,7 +400,6 @@ function node_preview($node) {
$output = theme('node_preview', $cloned_node);
}
drupal_set_title(t('Preview'));
drupal_set_breadcrumb(array(l(t('Home'), NULL), l(t('Create content'), 'node/add'), l(t('Submit @name', array('@name' => node_get_types('name', $node))), 'node/add/'. $node->type)));
return $output;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment