What is mem_cache ? How do you put a database query into that ?
Answer Posted / salil
1. "memcached" is a high-performance, distributed memory
object caching system
2. "memcache" is a php module, which provides procedural and
object oriented interface to memcached server.
3. PHP Usage: ($Value can be the mysql result data array)
$CacheInstance = new Memcache;
$CacheInstance->addServer($Host,$Port);
// STORE
$CacheInstance->set($Key,$Value,MEMCACHE_COMPRESSED,$TTL);
// FETCH
$CacheInstance->get($Key);
// DELETE
$CacheInstance->delete($Key);
| Is This Answer Correct ? | 4 Yes | 1 No |
Post New Answer View All Answers
What is singleton class in php?
Explain how we can get the number of elements in an array?
How is the ternary conditional operator used in php?
How do sessions work in php?
Will php die?
What are the steps involved to run php?
What kind of variable is age?
How do I escape data before storing it in the database?
What is php and why we use it?
Do you know what is the difference between the include() and require() functions?
What are the method available in form submitting?
What is the actually used php version?
Tell me how do you execute a php script from the command line?
Tell me how to retrieve a cookie value?
What is the use of mysqli_real_escape_string() function?