content type


  
      function set_content_type()
      {
          preg_match("#content-type:([^\r\n]*)#i", this->response_headers, matches);
  
          if (trim(matches[1]) != '')
          {
              content_type_array = explode(';', matches[1]);
              this->content_type = strtolower(trim(content_type_array[0]));
          }
      }