diff --git a/modules/widget/widget.controller.php b/modules/widget/widget.controller.php index 613ea39d3..8c6587b9d 100644 --- a/modules/widget/widget.controller.php +++ b/modules/widget/widget.controller.php @@ -374,58 +374,35 @@ class widgetController extends widget return $widget_content; } - $oCacheHandler = CacheHandler::getInstance('template'); - if($oCacheHandler->isSupport()) + /** + * Cache number and cache values are set so that the cache file should call + */ + FileHandler::makeDir($this->cache_path); + // Wanted cache file + $cache_file = sprintf('%s%d.%s.cache', $this->cache_path, $widget_sequence, $lang_type); + // If the file exists in the cache, the file validation + if(!$ignore_cache && file_exists($cache_file)) { - $key = 'widget_cache:' . $widget_sequence; - - $cache_body = $oCacheHandler->get($key); - $cache_body = preg_replace('@<\!--#Meta:@', '