File: example.php

Recommend this page to a friend!
  Classes of Cesar D. Rodas  >  PHPCached  >  example.php  >  Download  
File: example.php
Role: Example script
Content type: text/plain
Description: Example
Class: PHPCached
memcache client in pure PHP
Author: By
Last change: * Making visible without user login
Date: 14 years ago
Size: 314 bytes
 

Contents

Class file image Download
<?php
include("gMemcache.php");
$memcache = new gMemCache("localhost","11211");
$v = $memcache->get("xcesar");

if (
$v == false) print "no existe en memcache";
else print
"<pre>".print_r($v,true)."</pre>";
/* Setting a value */
$memcache->set("xcesar", range(0,140),0,true);
$memcache->disconnect();

?>

For more information send a message to info at phpclasses dot org.