From 3c9b42eb21ccec2d7e087d8f9df3f4cf0bd70ce0 Mon Sep 17 00:00:00 2001 From: Marco Antonio Nina Date: Wed, 22 Oct 2014 14:51:18 -0400 Subject: [PATCH] Improvement generate file support --- gulliver/system/class.g.php | 2 +- workflow/engine/controllers/adminProxy.php | 13 ++++++++++--- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/gulliver/system/class.g.php b/gulliver/system/class.g.php index a21283fb6..20962ce0d 100755 --- a/gulliver/system/class.g.php +++ b/gulliver/system/class.g.php @@ -5578,7 +5578,7 @@ class G $clean = trim(str_replace($strip, "", strip_tags($string))); $clean = preg_replace('/\s+/', "-", $clean); $clean = ($alpha) ? preg_replace("/[^a-zA-Z0-9]/", "", $clean) : $clean ; - $clean = ($force_lowercase) ? (function_exists('mb_strtolower')) ? mb_strtolower($clean, 'UTF-8') : strtolower($clean) : $clean; + $clean = ($lowercase) ? (function_exists('mb_strtolower')) ? mb_strtolower($clean, 'UTF-8') : strtolower($clean) : $clean; return $clean; } } diff --git a/workflow/engine/controllers/adminProxy.php b/workflow/engine/controllers/adminProxy.php index 15a0f3c1b..cbd5f8ad3 100644 --- a/workflow/engine/controllers/adminProxy.php +++ b/workflow/engine/controllers/adminProxy.php @@ -1368,7 +1368,14 @@ class adminProxy extends HttpProxyController //License Information: $activeLicense = $licenseManager->getActiveLicense(); - $params['license'] = $licenseManager; + $licenseInfo = array(); + $noInclude = array('licensedfeaturesList', 'result', 'serial'); + foreach ($licenseManager as $index => $value) { + if (!in_array($index, $noInclude)) { + $licenseInfo[$index] = G::sanitizeInput($value); + } + } + $params['license'] = $licenseInfo; //Operative System version (Linux, Windows) try { @@ -1391,9 +1398,9 @@ class adminProxy extends HttpProxyController //ProcessMaker Version $params['pmVersion'] = System::getVersion(); if (file_exists(PATH_DATA. 'log/upgrades.log')) { - $params['pmUpgrade'] = file_get_contents(PATH_DATA. 'log/upgrades.log', 'r'); + $params['pmUpgrade'] = serialize(file_get_contents(PATH_DATA. 'log/upgrades.log', 'r')); } else { - $params['pmUpgrade'] = G::LoadTranslation('ID_UPGRADE_NEVER_UPGRADE'); + $params['pmUpgrade'] = serialize(G::LoadTranslation('ID_UPGRADE_NEVER_UPGRADE')); } //Database server Version (MySQL version)