From: hickert Date: Thu, 9 Nov 2006 07:29:44 +0000 (+0000) Subject: Added an additional info string when certificates are invalid. X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=2623516ca68e1059bc8f34565719c64563282933;p=gosa.git Added an additional info string when certificates are invalid. git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@5054 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/plugins/personal/generic/class_user.inc b/plugins/personal/generic/class_user.inc index 2c546dfab..b334c6c47 100644 --- a/plugins/personal/generic/class_user.inc +++ b/plugins/personal/generic/class_user.inc @@ -455,8 +455,25 @@ class user extends plugin /* Read out data*/ $timeto = $certificate->getvalidto_date(); $timefrom = $certificate->getvalidfrom_date(); - $str = "
CN".preg_replace("/ /", " ", $certificate->getname())."

". - sprintf(_("Certificate is valid from %s to %s and is currently %s."), "".date('d M Y',$timefrom)."","".date('d M Y',$timeto)."", $certificate->isvalid()?""._("valid")."":""._("invalid").""); + + /* Additional info if start end time is '0' */ + $add_str_info = ""; + if($timeto == 0 && $timefrom == 0){ + $add_str_info = "
"._("(Some types of certificates are currently not supported and may be displayed as 'invalid'.").""; + } + + $str = " + + + + +
CN".preg_replace("/ /", " ", $certificate->getname())."

". + + sprintf(_("Certificate is valid from %s to %s and is currently %s."), + "".date('d M Y',$timefrom)."", + "".date('d M Y',$timeto)."", + $certificate->isvalid()?""._("valid")."": + ""._("invalid")."").$add_str_info; $smarty->assign($cert."info",$str); $smarty->assign($cert."_state","true"); } else {