src/Application/Config.php
private function getServerConfig() {

		$this->server['apc_on'] = extension_loaded('apc') && function_exists('apc_add') && ini_get('apc.enabled') && ini_get('apc.rfc1867');

		$fs = ini_get('upload_max_filesize');
		$suffix = strtoupper(substr($fs, -1));
		switch($suffix) {
			case 'K':
				$mult = 1024; break;
			case 'M':
				$mult = 1024*1024; break;
			case 'G':
				$mult = 1024*1024*1024; break;
			default:
				$mult = 0;
		}

		$this->server['max_upload_filesize'] = $mult ? (float) (substr($fs, 0, -1)) * $mult : (int) $fs;

	}
private function getServerConfig() {

		$this->server['apc_on'] = extension_loaded('apc') && function_exists('apc_add') && ini_get('apc.enabled') && ini_get('apc.rfc1867');

		$fs = ini_get('upload_max_filesize');
		$suffix = strtoupper(substr($fs, -1));
		switch($suffix) {
			case 'K':
				$mult = 1024; break;
			case 'M':
				$mult = 1024*1024; break;
			case 'G':
				$mult = 1024*1024*1024; break;
			default:
				$mult = 0;
		}

		$this->server['max_upload_filesize'] = $mult ? (float) (substr($fs, 0, -1)) * $mult : (int) $fs;

	}
private function getServerConfig ( ) { $ this -> server [ 'apc_on' ] = extension_loaded ( 'apc' ) && function_exists ( 'apc_add' ) && ini_get ( 'apc.enabled' ) && ini_get ( 'apc.rfc1867' ) ; $ fs = ini_get ( 'upload_max_filesize' ) ; $ suffix = strtoupper ( substr ( $ fs , - 1 ) ) ; switch ( $ suffix ) { case 'K' : $ mult = 1024 ; break ; case 'M' : $ mult = 1024 * 1024 ; break ; case 'G' : $ mult = 1024 * 1024 * 1024 ; break ; default : $ mult = 0 ; } $ this -> server [ 'max_upload_filesize' ] = $ mult ? ( float ) ( substr ( $ fs , 0 , - 1 ) ) * $ mult : ( int ) $ fs ; }
add particular information regarding server configuration, like PHP extensions
add particular information regarding server configuration like PHP extensions