function esi_fast_404 in ESI: Edge Side Includes 7.3
Generate a fast 404 (consisting of a single HTML comment). Full delivery is not desired, because it would typically result in embedding a complete, themed Drupal 404 page *within* another page.
See also
1 call to esi_fast_404()
- esi_handle_component in ./
esi.pages.inc - Menu callback to handle an ESI component.
File
- ./
esi.pages.inc, line 105 - Delivery handlers for the ESI module.
Code
function esi_fast_404() {
drupal_add_http_header('Status', '404 Not Found');
drupal_add_http_header('X-ESI', 'Component not recognised');
watchdog('page not found', check_plain($_GET['q']), NULL, WATCHDOG_WARNING);
// Unlike drupal_fast_404(), the HTML furniture (html tag, head tag, etc) are
// not delivered
echo "<!-- esi_fast_404 -->\n";
// Unlike normal page-views, invoking hook_exit() is unneccessary overhead.
// This use of exit matches the behaviour of drupal_fast_404().
exit;
}