Home > Backend Development > PHP Tutorial > PHP联接Memcache代码

PHP联接Memcache代码

WBOY
Release: 2016-06-13 12:22:15
Original
672 people have browsed it

PHP连接Memcache代码

<?php$mem = new Memcache;$mem->connect('127.0.0.1', 11211) or die ("Could not connect");$mem->set('key', 'This is a test!', 0, 60);$val = $mem->get('key');echo $val;?>
Copy after login

 

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template