Skip to content

Commit 80f0f50

Browse files
committed
minor #13962 [HttpFoundation] Document HeaderUtils::parseQuery() (javiereguiluz)
This PR was squashed before being merged into the master branch. Discussion ---------- [HttpFoundation] Document HeaderUtils::parseQuery() Fixes #13896. Commits ------- 264aaf1 [HttpFoundation] Document HeaderUtils::parseQuery()
2 parents fcf2eba + 264aaf1 commit 80f0f50

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

components/http_foundation.rst

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -272,6 +272,14 @@ this complexity and defines some methods for the most common tasks::
272272
HeaderUtils::unquote('"foo \"bar\""');
273273
// => 'foo "bar"'
274274

275+
// Parses a query string but maintains dots (PHP parse_str() replaces '.' by '_')
276+
HeaderUtils::parseQuery('foo[bar.baz]=qux');
277+
// => ['foo' => ['bar.baz' => 'qux']]
278+
279+
.. versionadded:: 5.2
280+
281+
The ``parseQuery()`` method was introduced in Symfony 5.2.
282+
275283
Accessing ``Accept-*`` Headers Data
276284
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
277285

0 commit comments

Comments
 (0)