You have to give the page a path -- what path you give doesn't really matter, exactly, but pick something you won't want to use as a real path on the site (I just use /404 for my own sites) -- and then enter the URL you used into the system configuration form for the path for the 404 page.
Drupal doesn't have a simple 'plug this into the 404' handler. It just takes whatever URL you give it and uses that output for 404 (also for 403).
Just for reference:
If You enable the "Disable Drupal blocks/regions" panels option, Drupal renders the page twice (one panels page content and one "The requested page could not be found." page content).
Yes, only on the 404 page.
This feature is coming from the ctools_context_handler_render function:
// Only directly output if $page was set to true.
if (!empty($info['no_blocks'])) {
print theme('page', $info['content'], FALSE);
return;
}
else {
return $info['content'];
}
and in drupal_not_found function:
if ($path && $path != $_GET['q']) {
// Set the active item in case there are tabs to display, or other
// dependencies on the path.
menu_set_active_item($path);
$return = menu_execute_active_handler($path); //<---- Panel page rendered
}
....
// To conserve CPU and bandwidth, omit the blocks.
print theme('page', $return, FALSE); //<- second page rendered
Closing this issue as outdated as Drupal 6 ctools is not supported. If this issue is relevant for Drupal 7, feel free to re-open and mark for Drupal 7 (or 8)
Comments
Comment #1
merlinofchaos commentedYou have to give the page a path -- what path you give doesn't really matter, exactly, but pick something you won't want to use as a real path on the site (I just use /404 for my own sites) -- and then enter the URL you used into the system configuration form for the path for the 404 page.
Drupal doesn't have a simple 'plug this into the 404' handler. It just takes whatever URL you give it and uses that output for 404 (also for 403).
Comment #2
delykj commentedThanks Merlin,
Just for reference:
If You enable the "Disable Drupal blocks/regions" panels option, Drupal renders the page twice (one panels page content and one "The requested page could not be found." page content).
Comment #3
merlinofchaos commentedIs this only on the 404 page?
Comment #4
delykj commentedYes, only on the 404 page.
This feature is coming from the ctools_context_handler_render function:
and in drupal_not_found function:
Comment #5
merlinofchaos commentedPretty awesome. There is probably absolutely nothing we can do about that.
Comment #7
broncomania commentedI agree with this problem and there is no solution out yet? because it looks ... ugly.
Comment #8
merlinofchaos commentedI think the solution is to not check the ignore blocks box?
Comment #9
broncomania commentedhmm sounds logical :-), but what about the regions that will be displayed?
Should i make an own page template without this regions?
Comment #10
luksakWhy is this marked as fixed? It is not really... Right?
Comment #11
luksakDidn't mean to change the version...
Comment #12
japerryClosing this issue as outdated as Drupal 6 ctools is not supported. If this issue is relevant for Drupal 7, feel free to re-open and mark for Drupal 7 (or 8)