This blog post explained a feature that was reverted before the release of
Symfony 4.2. That's why the original blog post content has been removed. You can
keep using the following Request
methods to work with request formats and
MIME types: getMimeType()
, getFormat()
, getRequestFormat()
,
getContentType()
and getAcceptableContentTypes()
.
New in Symfony 4.2: Acceptable Request Formats
October 26, 2018 • Published by Javier Eguiluz
Warning: This post is about an unsupported Symfony version. Some of this information may be out of date. Read the most recent Symfony Docs.
Help the Symfony project!
As with any Open-Source project, contributing code or documentation is the most common way to help, but we also have a wide range of sponsoring opportunities.
Comments are closed.
To ensure that comments stay relevant, they are closed for old posts.
Which would be the equivalent for '/' ???
Formats are defined in one internationnaly norm ?
Since the code is :
There's no format for /.
You can maybe trye to add your own like :
'' => array('/*'),
Thanks for the feedbacks. This has been reverted in https://github.com/symfony/symfony/pull/29047