Пример #1
0
 public function getInfo()
 {
     $info = array();
     $version = new JVersion();
     $platform = new JPlatform();
     $db = JFactory::getDbo();
     if (isset($_SERVER['SERVER_SOFTWARE'])) {
         $sf = $_SERVER['SERVER_SOFTWARE'];
     } else {
         $sf = getenv('SERVER_SOFTWARE');
     }
     $info['php'] = php_uname();
     $info['dbversion'] = $db->getVersion();
     $info['dbcollation'] = $db->getCollation();
     $info['phpversion'] = phpversion();
     $info['server'] = $sf;
     $info['sapi_name'] = php_sapi_name();
     $info['version'] = $version->getLongVersion();
     $info['platform'] = $platform->getLongVersion();
     $info['useragent'] = isset($_SERVER['HTTP_USER_AGENT']) ? $_SERVER['HTTP_USER_AGENT'] : "";
     $info['j2store_version'] = $this->getJ2storeVerion();
     $info['is_pro'] = J2Store::isPro();
     $info['curl'] = $this->_isCurl();
     $info['json'] = $this->_isJson();
     $config = JFactory::getConfig();
     $info['error_reporting'] = $config->get('error_reporting');
     $caching = $config->get('caching');
     $info['caching'] = $caching ? JText::_('J2STORE_ENABLED') : JText::_('J2STORE_DISABLED');
     $cache_plugin = JPluginHelper::isEnabled('system', 'cache');
     $info['plg_cache_enabled'] = $cache_plugin;
     $info['memory_limit'] = ini_get('memory_limit');
     return $info;
 }
Пример #2
0
 /**
  * Method to get the system information
  *
  * @return  array system information values
  *
  * @since   1.6
  */
 public function &getInfo()
 {
     if (!is_null($this->info)) {
         return $this->info;
     }
     $this->info = array();
     $version = new JVersion();
     $platform = new JPlatform();
     $db = JFactory::getDbo();
     $this->info['php'] = php_uname();
     $this->info['dbversion'] = $db->getVersion();
     $this->info['dbcollation'] = $db->getCollation();
     $this->info['phpversion'] = phpversion();
     $this->info['server'] = isset($_SERVER['SERVER_SOFTWARE']) ? $_SERVER['SERVER_SOFTWARE'] : getenv('SERVER_SOFTWARE');
     $this->info['sapi_name'] = php_sapi_name();
     $this->info['version'] = $version->getLongVersion();
     $this->info['platform'] = $platform->getLongVersion();
     $this->info['useragent'] = isset($_SERVER['HTTP_USER_AGENT']) ? $_SERVER['HTTP_USER_AGENT'] : "";
     return $this->info;
 }
 /**
  * Method to generate the log file header.
  *
  * @return  string  The log file header
  *
  * @since   11.1
  */
 protected function generateFileHeader()
 {
     $head = array();
     // Build the log file header.
     // If the no php flag is not set add the php die statement.
     if (empty($this->options['text_file_no_php'])) {
         // Blank line to prevent information disclose: https://bugs.php.net/bug.php?id=60677
         $head[] = '#';
         $head[] = '#<?php die(\'Forbidden.\'); ?>';
     }
     $head[] = '#Date: ' . gmdate('Y-m-d H:i:s') . ' UTC';
     $head[] = '#Software: ' . JPlatform::getLongVersion();
     $head[] = '';
     // Prepare the fields string
     $head[] = '#Fields: ' . strtolower(str_replace('}', '', str_replace('{', '', $this->format)));
     $head[] = '';
     return implode("\n", $head);
 }
Пример #4
0
 /**
  * Method to get the system information
  *
  * @return  array  System information values
  *
  * @since   1.6
  */
 public function &getInfo()
 {
     if (!empty($this->info)) {
         return $this->info;
     }
     $version = new JVersion();
     $platform = new JPlatform();
     $db = $this->getDbo();
     $this->info = array('php' => php_uname(), 'dbversion' => $db->getVersion(), 'dbcollation' => $db->getCollation(), 'dbconnectioncollation' => $db->getConnectionCollation(), 'phpversion' => phpversion(), 'server' => isset($_SERVER['SERVER_SOFTWARE']) ? $_SERVER['SERVER_SOFTWARE'] : getenv('SERVER_SOFTWARE'), 'sapi_name' => php_sapi_name(), 'version' => $version->getLongVersion(), 'platform' => $platform->getLongVersion(), 'useragent' => isset($_SERVER['HTTP_USER_AGENT']) ? $_SERVER['HTTP_USER_AGENT'] : "");
     return $this->info;
 }
Пример #5
0
 /**
  * method to get the system information
  *
  * @return array system information values
  */
 function &getInfo()
 {
     if (is_null($this->info)) {
         $this->info = array();
         $version = new JVersion();
         $platform = new JPlatform();
         $db = JFactory::getDBO();
         if (isset($_SERVER['SERVER_SOFTWARE'])) {
             $sf = $_SERVER['SERVER_SOFTWARE'];
         } else {
             $sf = getenv('SERVER_SOFTWARE');
         }
         $this->info['php'] = php_uname();
         $this->info['dbversion'] = $db->getVersion();
         $this->info['dbcollation'] = $db->getCollation();
         $this->info['phpversion'] = phpversion();
         $this->info['server'] = $sf;
         $this->info['sapi_name'] = php_sapi_name();
         $this->info['version'] = $version->getLongVersion();
         $this->info['platform'] = $platform->getLongVersion();
         $this->info['useragent'] = phpversion() <= '4.2.1' ? getenv("HTTP_USER_AGENT") : $_SERVER['HTTP_USER_AGENT'];
     }
     return $this->info;
 }
Пример #6
0
 /**
  * Method to get the system information
  *
  * @return  array  System information values
  */
 public function getInfo()
 {
     if (is_null($this->info)) {
         $version = new \JVersion();
         $platform = new \JPlatform();
         $db = \App::get('db');
         if (isset($_SERVER['SERVER_SOFTWARE'])) {
             $sf = $_SERVER['SERVER_SOFTWARE'];
         } else {
             $sf = getenv('SERVER_SOFTWARE');
         }
         $this->info = array();
         $this->info['php'] = php_uname();
         $this->info['dbversion'] = $db->getVersion();
         $this->info['dbcollation'] = $db->getCollation();
         $this->info['phpversion'] = phpversion();
         $this->info['server'] = $sf;
         $this->info['sapi_name'] = php_sapi_name();
         $this->info['version'] = $version->getLongVersion();
         $this->info['platform'] = $platform->getLongVersion();
         $this->info['useragent'] = $_SERVER['HTTP_USER_AGENT'];
     }
     return $this->info;
 }
Пример #7
0
 /**
  * This checks for the correct Long Version.
  *
  * @return void
  */
 public function testGetLongVersion()
 {
     $expected = 'Joomla Platform 11.1.0 Dev [ Ember ] 15-Apr-2011 00:00 GMT';
     $this->assertEquals($expected, JPlatform::getLongVersion(), 'Should get the correct Long Version');
 }
Пример #8
0
 /**
  * Method to get the system information
  *
  * @return  array system information values
  *
  * @since   1.6
  */
 public function &getInfo()
 {
     if (is_null($this->info)) {
         $this->info = array();
         $version = new JVersion();
         $platform = new JPlatform();
         $db = JFactory::getDbo();
         if (isset($_SERVER['SERVER_SOFTWARE'])) {
             $sf = $_SERVER['SERVER_SOFTWARE'];
         } else {
             $sf = getenv('SERVER_SOFTWARE');
         }
         //Get PlayJoom Version
         require_once JPATH_BASE . '/components/com_playjoomupdate/helpers/pjversion.php';
         if (!defined('PJVERSION')) {
             $jversion = new PJVersion();
             $this->info['pj_version'] = $jversion->getLongVersion();
         }
         //Get getID3 Version
         require_once JPATH_BASE . '/components/com_playjoom/helpers/id3/getid3.php';
         $getID3 = new getID3();
         $this->info['getID3_version'] = $getID3->version();
         $this->info['php'] = php_uname();
         $this->info['dbversion'] = $db->getVersion();
         $this->info['dbcollation'] = $db->getCollation();
         $this->info['phpversion'] = phpversion();
         $this->info['server'] = $sf;
         $this->info['sapi_name'] = php_sapi_name();
         $this->info['version'] = $version->getLongVersion();
         $this->info['platform'] = $platform->getLongVersion();
         $this->info['useragent'] = $_SERVER['HTTP_USER_AGENT'];
     }
     return $this->info;
 }