drupal_not_found

Хочешь помочь с переводом? Это очень просто и быстро. Лишь зарегистрируйся, и можешь тут же начать переводить.

includes/common.inc, строка 349

Версии
5 – 6
drupal_not_found()

Генерирует ошибку 404 (страница не найдена) если запрос не удалось обработать.

▾ 16 функции вызывают drupal_not_found()

book_export in modules/book/book.pages.inc
Menu callback; Generates various representation of a book page and its children.
file_download in includes/file.inc
Call modules that implement hook_file_download() to find out if a file is accessible and what headers it should be transferred with. If a module returns -1 drupal_access_denied() will be returned. If one or more modules returned headers the download...
file_transfer in includes/file.inc
Transfer file using http to client. Pipes a file through Drupal to the client.
filter_admin_delete in modules/filter/filter.admin.inc
Menu callback; confirm deletion of a format. See alsofilter_admin_delete_submit()
locale_languages_delete_form in includes/locale.inc
User interface for the language deletion confirmation screen.
locale_languages_edit_form in includes/locale.inc
Editing screen for a particular language.
locale_translate_delete_page in includes/locale.inc
String deletion confirmation page.
profile_browse in modules/profile/profile.pages.inc
Menu callback; display a list of user information.
profile_field_delete in modules/profile/profile.admin.inc
Menu callback; deletes a field from all user profiles.
profile_field_form in modules/profile/profile.admin.inc
Menu callback: Generate a form to add/edit a user profile field. See alsoprofile_field_form_validate()
statistics_access_log in modules/statistics/statistics.admin.inc
Menu callback; Displays recent page accesses.
statistics_node_tracker in modules/statistics/statistics.pages.inc
statistics_user_tracker in modules/statistics/statistics.pages.inc
system_main_admin_page in modules/system/system.admin.inc
Menu callback; Provide the administration overview page.
taxonomy_admin_term_edit in modules/taxonomy/taxonomy.admin.inc
Страница редактирования термина словаря.
taxonomy_term_page in modules/taxonomy/taxonomy.pages.inc
Коллбэк меню; отображает все ноды, связанные с термином таксономии.

Код

<?php
function drupal_not_found() {
  drupal_set_header('HTTP/1.1 404 Not Found');

  watchdog('page not found', check_plain($_GET['q']), NULL, WATCHDOG_WARNING);

  $path = drupal_get_normal_path(variable_get('site_404', ''));
  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);
  }

  if (empty($return) || $return == MENU_NOT_FOUND || $return == MENU_ACCESS_DENIED) {
    drupal_set_title(t('Page not found'));
    $return = t('The requested page could not be found.');
  }

  // To conserve CPU and bandwidth, omit the blocks.
  print theme('page', $return, FALSE);
}
?>
Войдите или зарегистрируйтесь, чтобы получить возможность отправлять комментарии

Вход в систему