Browse Source

Add renew session cookie on page load

master
Skylar Ittner 2 years ago
parent
commit
bae6d1ac17
1 changed files with 2 additions and 0 deletions
  1. 2
    0
      required.php

+ 2
- 0
required.php View File

@@ -14,6 +14,8 @@ $session_length = 60 * 60; // 1 hour
session_set_cookie_params($session_length, "/", null, false, true);

session_start(); // stick some cookies in it
// renew session cookie
setcookie(session_name(), session_id(), time() + $session_length);
//
// Composer
require __DIR__ . '/vendor/autoload.php';

Loading…
Cancel
Save