Exemplo n.º 1
0
     $params = md5($uri[1]);
 } else {
     $params = md5('');
 }
 $uri = array_filter(explode('/', $uri[0]));
 foreach ($uri as $key => $value) {
     $uri[$key] = md5($value);
 }
 $uri[] = $params;
 unset($params);
 require_once __DIR__ . '/../src/Interfaces/EngineInterface.php';
 require_once $vanillaEngineFile;
 try {
     $engine = new Engine($config);
     if ($engine instanceof \Esemve\VanillaCache\Interfaces\EngineInterface) {
         $content = $engine->getVanillaCacheContent($uri);
         if ($content) {
             require_once __DIR__ . '/../src/Parser.php';
             $parser = new \Esemve\VanillaCache\Parser($engine);
             echo $parser->parse($content);
             die;
         }
     }
 } catch (Exception $e) {
 }
 unset($content);
 unset($uri);
 unset($params);
 unset($server);
 unset($vanillaConfig);
 unset($vanillaStorageFolder);