From cea94f4d091efbecd7bbdab1b4dcee5f99f8ce81 Mon Sep 17 00:00:00 2001 From: Dimitri Gritsajuk Date: Fri, 9 Nov 2018 10:12:31 +0100 Subject: [PATCH] Rename content_type header to content-type --- controller.rst | 2 +- create_framework/http_foundation.rst | 2 +- introduction/http_fundamentals.rst | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/controller.rst b/controller.rst index 86b5c5f07ca..5b0f940ca2f 100644 --- a/controller.rst +++ b/controller.rst @@ -522,7 +522,7 @@ the ``Request`` class:: // retrieves an HTTP request header, with normalized, lowercase keys $request->headers->get('host'); - $request->headers->get('content_type'); + $request->headers->get('content-type'); } The ``Request`` class has several public properties and methods that return any diff --git a/create_framework/http_foundation.rst b/create_framework/http_foundation.rst index 79ff1c953a6..a7c4065d842 100644 --- a/create_framework/http_foundation.rst +++ b/create_framework/http_foundation.rst @@ -192,7 +192,7 @@ fingertips thanks to a nice and simple API:: // retrieve an HTTP request header, with normalized, lowercase keys $request->headers->get('host'); - $request->headers->get('content_type'); + $request->headers->get('content-type'); $request->getMethod(); // GET, POST, PUT, DELETE, HEAD $request->getLanguages(); // an array of languages the client accepts diff --git a/introduction/http_fundamentals.rst b/introduction/http_fundamentals.rst index c3ad78bf3dc..6e7cb1cf183 100644 --- a/introduction/http_fundamentals.rst +++ b/introduction/http_fundamentals.rst @@ -231,7 +231,7 @@ have all the request information at your fingertips:: // retrieves an HTTP request header, with normalized, lowercase keys $request->headers->get('host'); - $request->headers->get('content_type'); + $request->headers->get('content-type'); $request->getMethod(); // e.g. GET, POST, PUT, DELETE or HEAD $request->getLanguages(); // an array of languages the client accepts