You are here

public function Request::getMimeType in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/http-foundation/Request.php \Symfony\Component\HttpFoundation\Request::getMimeType()

Gets the mime type associated with the format.

Parameters

string $format The format:

Return value

string The associated mime type (null if not found)

File

vendor/symfony/http-foundation/Request.php, line 1311

Class

Request
Request represents an HTTP request.

Namespace

Symfony\Component\HttpFoundation

Code

public function getMimeType($format) {
  if (null === static::$formats) {
    static::initializeFormats();
  }
  return isset(static::$formats[$format]) ? static::$formats[$format][0] : null;
}