Quote
public integer $duration;
number of seconds that the data can remain in cache. Defaults to 60 seconds. If it is 0, existing cached content would be removed from the cache. If it is a negative value, the cache will be disabled (any existing cached content will remain in the cache.)
Note, if cache dependency changes or cache space is limited, the data may be purged out of cache earlier.
number of seconds that the data can remain in cache. Defaults to 60 seconds. If it is 0, existing cached content would be removed from the cache. If it is a negative value, the cache will be disabled (any existing cached content will remain in the cache.)
Note, if cache dependency changes or cache space is limited, the data may be purged out of cache earlier.
In this code if we don't define the duration property the content as default regenerate each 60 seconds?
beginCache('categoriesMenu',array('dependency'=>array( 'class'=>'system.caching.dependencies.CDbCacheDependency', 'sql'=>'SELECT unix_timestamp(MAX(update_date))+count(*) FROM category', )))): ?>
I think due we have an dependency, until this dependency is valid duration is not matter. Do i think right?