Commit 6539cce2 authored by Eric Mann's avatar Eric Mann
Browse files

Merge pull request #2 from hans2103/patch-2

parents 4e0a27f5 3912bd31
......@@ -11,3 +11,28 @@ A WordPress object cache backend that implements all available methods using Red
2. Install Predis (included in this repository as a submodule) in the `/wp-content/predis` directory, since that's where the object cache expects it to reside.
3. Add object-cache.php to the wp-content directory. It is a drop-in file, not a plugin, so it belongs in the wp-content directory, not the plugins directory.
4. By default, the script will connect to Redis at
### Connecting to Redis ###
By default Predis uses `` and `6379` as the default host and port when creating a new client
instance without specifying any connection parameter:
$redis = new Predis\Client();
$redis->set('foo', 'bar');
$value = $redis->get('foo');
It is possible to specify the various connection parameters using URI strings or named arrays:
$redis = new Predis\Client('tcp://');
// is equivalent to:
$redis = new Predis\Client(array(
'scheme' => 'tcp',
'host' => '',
'port' => 6379,
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment