![]() |
Need a Tiny Caching Method - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21) +--- Thread: Need a Tiny Caching Method (/showthread.php?tid=31314) |
Need a Tiny Caching Method - El Forum - 06-14-2010 [eluser]Mareshal[/eluser] I need a simple caching method, without using a complicated caching script or something. I need this especially for site settings, and then I might extend this if it works. I was thinking to get all data from DB, and put all them into a hidden file, with a random generated name. Then, when I update the settings, just update the database, and in the same time the file. Would this be a good idea? Need a Tiny Caching Method - El Forum - 06-14-2010 [eluser]liamr[/eluser] You seen CI's built in cache library? Need a Tiny Caching Method - El Forum - 06-14-2010 [eluser]Mareshal[/eluser] [quote author="liamr" date="1276566497"]You seen CI's built in cache library?[/quote] No, when was added ? Need a Tiny Caching Method - El Forum - 06-14-2010 [eluser]Jelmer[/eluser] Take a look at this topic, the _export_preferences() function I described there. I took the approach of generating a normal config file from the DB, which can be (auto-)loaded like any normal config file for usage. Need a Tiny Caching Method - El Forum - 06-14-2010 [eluser]Mareshal[/eluser] Thanks Jelmer. Very very nice idea. Much more useful than mine. |