You are here

function protected_pages_enter_password_submit in Protected Pages 7.2

Same name and namespace in other branches
  1. 7 protected_pages.inc \protected_pages_enter_password_submit()

Implements hook_submit().

File

./protected_pages.inc, line 98
Provides page callbacks for enter password page.

Code

function protected_pages_enter_password_submit($form, &$form_state) {
  $_SESSION['_protected_page']['passwords'][$form_state['values']['protected_page_pid']]['request_time'] = REQUEST_TIME;
  $session_expire_time = variable_get('protected_pages_session_expire_time', 0);
  if ($session_expire_time) {
    $_SESSION['_protected_page']['passwords'][$form_state['values']['protected_page_pid']]['expire_time'] = strtotime("+{$session_expire_time} minutes");
  }
}