Skip to content
Fetching contributors…
Cannot retrieve contributors at this time
34 lines (29 sloc) 656 Bytes
--TEST--
Memcached::get()
--SKIPIF--
<?php if (!extension_loaded("memcached")) print "skip"; ?>
--FILE--
<?php
$m = new Memcached();
$m->addServer('localhost', 11211, 1);
$m->delete('foo');
error_reporting(0);
var_dump($m->get('foo'));
echo $m->getResultMessage(), "\n";
var_dump($m->get(''));
echo $m->getResultMessage(), "\n";
$m->set('foo', "asdf", 10);
var_dump($m->get('foo'));
echo $m->getResultMessage(), "\n";
$m->delete('foo');
var_dump($m->get(' ä foo jkh a s åäö'));
echo $m->getResultMessage(), "\n";
--EXPECT--
bool(false)
NOT FOUND
bool(false)
A BAD KEY WAS PROVIDED/CHARACTERS OUT OF RANGE
string(4) "asdf"
SUCCESS
bool(false)
NOT FOUND
Jump to Line
Something went wrong with that request. Please try again.