english/libraries/joomla/cache/storage/memcache.php
/**
	 * Test to see if the cache storage is available.
	 *
	 * @return  boolean  True on success, false otherwise.
	 */
Test to see if the cache storage is available.
@return  boolean  True on success, false otherwise.
Test to see if the cache storage is available . @return boolean True on success false otherwise .
public static function test()
	{
		if ((extension_loaded('memcache') && class_exists('Memcache')) != true ) {
			return false;
		}
		$config = JFactory::getConfig();
		$host = $config->get('memcache_server_host', 'localhost');
		$port = $config->get('memcache_server_port', 11211);
		$memcache = new Memcache;
		$memcachetest = @$memcache->connect($host, $port);
		 if (!$memcachetest) {
		 	return false;
		 } else {
		 	return true;
		 }
	}
public static function test ( ) { if ( ( extension_loaded ( 'memcache' ) && class_exists ( 'Memcache' ) ) != true ) { return false ; } $ config = JFactory :: getConfig ( ) ; $ host = $ config -> get ( 'memcache_server_host' , 'localhost' ) ; $ port = $ config -> get ( 'memcache_server_port' , 11211 ) ; $ memcache = new Memcache ; $ memcachetest = @ $ memcache -> connect ( $ host , $ port ) ; if ( ! $ memcachetest ) { return false ; } else { return true ; } }
Test to see if the cache storage is available.
Test to see if the cache storage is available .