You are here

function search404_help in Search 404 8

Same name and namespace in other branches
  1. 7 search404.module \search404_help()
  2. 2.x search404.module \search404_help()

Implements hook_help().

@inheritdoc

File

./search404.module, line 17
The search404 module file, does all the searching when a 404 occurs.

Code

function search404_help($route_name, RouteMatchInterface $route_match) {
  $output = '';
  switch ($route_name) {

    // Main module help for the download_all_files module.
    case 'help.page.search404':
      $config_link = Url::fromRoute('search404.settings');
      $link = Link::fromTextAndUrl(t('@text', [
        '@text' => 'search 404 settings',
      ]), $config_link)
        ->toString();
      $output .= '<h3>' . t('About') . '</h3>';
      $output .= '<p>' . t('Instead of showing a default "Page not found"
      for a 404 error, this module performs a search on the keywords in
      the URL and display results based on the search. You can add basic
      settings for the 404 resulting page and other search404
      configurations in @link page.', [
        '@link' => $link,
      ]) . '</p>';
      return $output;
  }
}