You are here

function autologout_help in Automated Logout 8

Same name and namespace in other branches
  1. 5 autologout.module \autologout_help()
  2. 6.4 autologout.module \autologout_help()
  3. 6 autologout.module \autologout_help()
  4. 6.2 autologout.module \autologout_help()
  5. 6.3 autologout.module \autologout_help()
  6. 7.2 autologout.module \autologout_help()
  7. 7.4 autologout.module \autologout_help()

Implements hook_help().

File

./autologout.module, line 17
Automated Logout - Module.

Code

function autologout_help($route_name, RouteMatchInterface $route_match) {
  switch ($route_name) {
    case 'help.page.autologout':
      $seconds = \Drupal::service('autologout.manager')
        ->getUserTimeout();
      $output = '';
      $output .= '<h3>' . t('About') . '</h3>';
      $output .= '<p>' . t("This module allows you to force site users to be logged out after a given amount of time due to inactivity after first being presented with a confirmation dialog. Your current logout threshold is %seconds seconds.", [
        '%seconds' => $seconds,
      ]) . '</p>';
      return $output;
  }
}