diff --git a/src/CentreonLegacy/Core/Module/License.php b/src/CentreonLegacy/Core/Module/License.php index 9ac8617fb34f86ee6461d1d7d1ad8a865e88e4fd..7597d642c8650d5dfbdbe1fa5b609a51ab232a91 100644 --- a/src/CentreonLegacy/Core/Module/License.php +++ b/src/CentreonLegacy/Core/Module/License.php @@ -57,11 +57,11 @@ class License extends Module * * @return array */ - private function parseLicenseFile() + private function parseLicenseFile($licenseFile) { $info = array(); - $lines = preg_split('/\n/', file_get_contents($this->licenseFile)); + $lines = preg_split('/\n/', file_get_contents($licenseFile)); foreach ($lines as $line) { if (preg_match('/^([^= ]+)\s*=\s*(.+)$/', $line, $match)) { $info[$match[1]] = $match[2]; @@ -84,7 +84,7 @@ class License extends Module } else { $zend_info = $this->parseLicenseFile($licenseFile); } - $licenseExpiration = date("d/m/Y", strtotime($zend_info['Expires'])); + $licenseExpiration = strtotime($zend_info['Expires']); } else { $licenseExpiration = _("N/A"); } diff --git a/www/include/options/oreon/modules/listModules.ihtml b/www/include/options/oreon/modules/listModules.ihtml index ae7bf08ae2fbed4e6770e14b921883a5f35e5607..57db5de044b2e839b0d807c93704b700e6788100 100644 --- a/www/include/options/oreon/modules/listModules.ihtml +++ b/www/include/options/oreon/modules/listModules.ihtml @@ -23,7 +23,7 @@ <td class="ListColCenter">{$properties.installed_version}</td> <td class="ListColCenter">{$properties.author}</td> <!-- using a class to format the timestamp --> - <td class="ListColCenter isTimestamp">{$properties.license_expiration}</td> + <td class="ListColCenter isTimestamp isDate">{$properties.license_expiration}</td> <td class="ListColCenter">{$properties.installed}</td> <td id="{$properties.name}" class="ListColCenter"></td> <td id="action_{$properties.name}" class="ListColRight">