CakePHP - Store a cache in a database and use it with Javascript -


with cakephp, want cache content of variables , store in database.

i want fetch cache javascript (and cakephp).

what kind of solutions can use ?

edit : more specific, calculate statistitcs cakephp , don't calculate every time, cache results. have application developped phonegap same thing. ideal thing have single cache, stored in database, , each application use cache in database.

i suppose store statistical data in array() format that:

array(     'sum' => $sum_value,     'max' => $max_value,     ... ) 

after simple json_encode() above array , save in cache field, using convinient save method. when retrieving cache field can json_decode() data , have array ready modification , update.

as javascript, believe want use ajax functionality. can retrieve, store , update cache field using ajax easily. documentation quite explainable handling ajax requests.

i hope helps


Comments

Popular posts from this blog

php - Calling a template part from a post -

Firefox SVG shape not printing when it has stroke -

How to mention the localhost in android -