Skip to content

Instantly share code, notes, and snippets.

@johncongdon
Last active August 29, 2015 14:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save johncongdon/eb50cfd27212351c607c to your computer and use it in GitHub Desktop.
Save johncongdon/eb50cfd27212351c607c to your computer and use it in GitHub Desktop.
14 public function __construct()
15 {
16 $config = Util_Config::getValue("memcache");
17 if (isset($config['servers']))
18 {
19 $memcache = new Memcached();
20 print rand(1,9999999) . "<meta http-equiv=refresh content=2>";
21 foreach ($config['servers'] as $server)
22 {
23 $memcache->addServer($server['host'], $server['port']);
24 }
25 $this->memcache = $memcache;
26 var_dump($memcache);
27 var_dump($this);
28 }
29 }
object(Memcached)[4]
object(Util_Memcache)[3]
protected 'memcache' => null
protected 'lock_timeout' => int 2
protected 'force_refresh' => boolean false
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment