Thinkphp Closing Cache Method Summary

Source: Internet
Author: User

Thinkphp in the data cache, including file mode, shared memory mode and database mode in a variety of ways to cache, through the plug-in method can also increase the need for later cache classes, so that application development can choose more suitable for their own cache, so as to effectively improve the efficiency of application execution. The caching methods currently supported include: File, Apachenote, Apc, Eaccelerator, Memcache, Shmop, Sqlite, Db, Redis, and XCache.
For more detailed information, please see: http://www.111cn.net/phper/thinkPhp/45890.htm
For the convenience of development, the cache can be removed.

1. Find thinkphp/common/convention.php and thinkphp/common/debug.php

2. Open these two files to find the settings you want.

(Bo main Note: This should be the old version of the thinkphp configuration path, the new version please refer to the latest development manual)

In debug.php

' tmpl_cache_on '= =false,      //  Open Template cache by default

In convention.php

tmpl_cache_on'   = False,  //default to turn on the template compilation cache false to recompile the template every time 'action_cache_on  '  false,  //  Close action cache by default 'html_cache_on  '   false,   //  close static cache by default

thinkphp How do I close all caches?

Truefalse false

Close the thinkphp template cache

Finally I find myself, and add a sentence in the config.php.

' tmpl_cache_on ' false , ' tmpl_cache_on ' false

This will regenerate the cache each time it is run

(This article is based on the old version of thinkphp, for reference only)

Thinkphp Closing Cache Method Summary (GO)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.