Commit ea36711d authored by Steven Wittens's avatar Steven Wittens

- #20910: Centralize print theme page fixes

parent e08bde4d
......@@ -208,13 +208,13 @@ function drupal_not_found() {
$status = MENU_NOT_FOUND;
if ($path) {
menu_set_active_item($path);
$status = menu_execute_active_handler();
$return = menu_execute_active_handler();
}
if ($status != MENU_FOUND) {
if (empty($return)) {
drupal_set_title(t('Page not found'));
print theme('page', '');
}
print theme('page', $return);
}
/**
......@@ -228,13 +228,14 @@ function drupal_access_denied() {
$status = MENU_NOT_FOUND;
if ($path) {
menu_set_active_item($path);
$status = menu_execute_active_handler();
$return = menu_execute_active_handler();
}
if ($status != MENU_FOUND) {
if (empty($return)) {
drupal_set_title(t('Access denied'));
print theme('page', message_access());
$return = message_access();
}
print theme('page', $return);
}
/**
......
......@@ -102,17 +102,17 @@ function blog_page($a = NULL, $b = NULL) {
if (is_numeric($a)) { // $a is a user ID
if ($b == 'feed') {
blog_feed_user($a);
return blog_feed_user($a);
}
else {
blog_page_user($a);
return blog_page_user($a);
}
}
else if ($a == 'feed') {
blog_feed_last();
return blog_feed_last();
}
else {
blog_page_last();
return blog_page_last();
}
}
......
......@@ -102,17 +102,17 @@ function blog_page($a = NULL, $b = NULL) {
if (is_numeric($a)) { // $a is a user ID
if ($b == 'feed') {
blog_feed_user($a);
return blog_feed_user($a);
}
else {
blog_page_user($a);
return blog_page_user($a);
}
}
else if ($a == 'feed') {
blog_feed_last();
return blog_feed_last();
}
else {
blog_page_last();
return blog_page_last();
}
}
......
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