System.get API - Return current PHP + MySQL time
authorTim Otten <totten@civicrm.org>
Sat, 5 Dec 2015 23:56:53 +0000 (15:56 -0800)
committerTim Otten <totten@civicrm.org>
Sat, 5 Dec 2015 23:56:53 +0000 (15:56 -0800)
api/v3/System.php

index 94b4384cade8e00734f6972e17e6b846e2f816c1..64e6d0ae8b9260e29720d0b8bb4b0d9c3d48dad1 100644 (file)
@@ -182,12 +182,14 @@ function civicrm_api3_system_get($params) {
       'uf' => CIVICRM_UF, // deprecated in favor of cms.type
       'php' => array(
         'version' => phpversion(),
+        'time' => time(),
         'tz' => date_default_timezone_get(),
         'extensions' => get_loaded_extensions(),
         'ini' => _civicrm_api3_system_get_redacted_ini(),
       ),
       'mysql' => array(
         'version' => CRM_Core_DAO::singleValueQuery('SELECT @@version'),
+        'time' => CRM_Core_DAO::singleValueQuery('SELECT unix_timestamp()'),
         'vars' => _civicrm_api3_system_get_redacted_mysql(),
       ),
       'cms' => array(