ecshop2.7.3 How to automatically clear the cache

Source: Internet
Author: User

1. Insert a piece of data into the Ecs_shop_config table


Enter Ecshop background-database management-sql Query


Copy the following SQL, paste into inside to execute. Note This is the default table prefix Ecs_, if you have changed to be unified with your.

INSERT into ' ecs_shop_config ' VALUES (65535, ten, ' last_clear_time ', ' text ', ', ', ', ' 1274090777 ', 1);



Note: 65535 this value can also be changed, but it is not recommended that less than 1000, if less than 1000, may have an impact on other values.

2. Find includes/init.php This file , Add the following code at the end of the file:

if (Is_temps ()) {    clear_all_files ();    $sql = "Update". $ecs->table (' Shop_config '). " Set value= ". Time ()." Where Code= ' "." Last_clear_time ' ";     $db->query ($sql);} function Is_temps () {    if (time ()-$_cfg[' Last_clear_time ']<10000)    {        return (false);    }    else    {        return (true);    

ecshop2.7.3 How to automatically clear the cache

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.