- Fix incorrect cache ttl used in get_cache_engine() (#1488447), use time() where mktime() without arguments was used
| | |
| | | $_SESSION['storage_port'] = $port; |
| | | $_SESSION['storage_ssl'] = $ssl; |
| | | $_SESSION['password'] = $this->encrypt($pass); |
| | | $_SESSION['login_time'] = mktime(); |
| | | $_SESSION['login_time'] = time(); |
| | | |
| | | if (isset($_REQUEST['_timezone']) && $_REQUEST['_timezone'] != '_default_') |
| | | $_SESSION['timezone'] = floatval($_REQUEST['_timezone']); |
| | |
| | | public function temp_gc() |
| | | { |
| | | $tmp = unslashify($this->config->get('temp_dir')); |
| | | $expire = mktime() - 172800; // expire in 48 hours |
| | | $expire = time() - 172800; // expire in 48 hours |
| | | |
| | | if ($tmp && ($dir = opendir($tmp))) { |
| | | while (($fname = readdir($dir)) !== false) { |
| | |
| | | { |
| | | if ($this->caching && !$this->cache) { |
| | | $rcube = rcube::get_instance(); |
| | | $ttl = $rcube->config->get('message_cache_lifetime', '10d') - mktime(); |
| | | $ttl = $rcube->config->get('message_cache_lifetime', '10d'); |
| | | $ttl = get_offset_time($ttl) - time(); |
| | | |
| | | $this->cache = $rcube->get_cache('IMAP', $this->caching, $ttl); |
| | | } |
| | | |
| | |
| | | $unit = 's'; |
| | | } |
| | | |
| | | $ts = mktime(); |
| | | $ts = time(); |
| | | switch ($unit) { |
| | | case 'w': |
| | | $amount *= 7; |