/** * Returns the MIME content type of an uploaded file. * @return string */ public function getContentType() { if ($this->isOk() && $this->type === NULL) { $this->type = NMimeTypeDetector::fromFile($this->tmpName); } return $this->type; }