Exemplo n.º 1
0
 /**
  * Returns array of headers
  *
  * @param array   $file CDN file array
  * @return array
  */
 function _get_headers($file)
 {
     $allowed_headers = array('Content-Length', 'Content-Type', 'Content-Encoding', 'Content-Language', 'Content-MD5', 'Cache-Control');
     $headers = parent::_get_headers($file, true);
     foreach ($headers as $header => $value) {
         if (!in_array($header, $allowed_headers)) {
             unset($headers[$header]);
         }
     }
     return $headers;
 }