CodeIgniter Forums
Turn Off Smarty Caching: How? Good or Bad? Partial Caching? - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: Turn Off Smarty Caching: How? Good or Bad? Partial Caching? (/showthread.php?tid=20325)



Turn Off Smarty Caching: How? Good or Bad? Partial Caching? - El Forum - 07-06-2009

[eluser]CodeIgniterNewbie[/eluser]
Per Google: "In general, HTML is not static, and shouldn't be considered cacheable." (http://code.google.com/speed/page-speed/docs/caching.html)

Per Smarty: "....if you are displaying the front page of your website that does not change its content very often, it might work well to cache this page for an hour or more. On the other hand, if you are displaying a page with a timetable containing new information by the minute, it would not make sense to cache this page." (http://www.smarty.net/manual/en/caching.php)

Since most of my site is dynamic, I decided to turn off Smarty caching. When I looked at Smarty.class.php, line 160, I saw this:

Code:
var $caching         =  0;

I'm sure that there is Smarty caching taking place on my site.

1. How do I turn off Smarty caching?
2. Am I right to want to turn off Smarty caching?
3. Can I do partial caching with Smarty (e.g. my footer TPL is probably not going to change often)

Thanks.