From 83fc0a59b1632a54f8cadb81f50115e9b7e61d19 Mon Sep 17 00:00:00 2001 From: Uwe Steinmann Date: Tue, 22 Sep 2020 10:03:30 +0200 Subject: [PATCH] add expiration in 3 years --- op/op.SetExpires.php | 4 ++++ views/bootstrap/class.SetExpires.php | 1 + 2 files changed, 5 insertions(+) diff --git a/op/op.SetExpires.php b/op/op.SetExpires.php index a1dad52b1..20fc29011 100644 --- a/op/op.SetExpires.php +++ b/op/op.SetExpires.php @@ -68,6 +68,10 @@ case "2y": $tmp = explode('-', date('Y-m-d')); $expires = mktime(0,0,0, $tmp[1], $tmp[2], $tmp[0]+2); break; +case "3y": + $tmp = explode('-', date('Y-m-d')); + $expires = mktime(0,0,0, $tmp[1], $tmp[2], $tmp[0]+3); + break; case "never": default: $expires = null; diff --git a/views/bootstrap/class.SetExpires.php b/views/bootstrap/class.SetExpires.php index 3aa15ddd6..426388f2e 100644 --- a/views/bootstrap/class.SetExpires.php +++ b/views/bootstrap/class.SetExpires.php @@ -74,6 +74,7 @@ $(document).ready( function() { $options[] = array('1m', getMLText('expire_in_1m')); $options[] = array('1y', getMLText('expire_in_1y')); $options[] = array('2y', getMLText('expire_in_2y')); + $options[] = array('3y', getMLText('expire_in_3y')); $this->formField( getMLText("preset_expires"), array(