How to request data in symfony using $request

  php, symfony

Symfony by default named form fields this way: entity[fiel].
So, i am trying to request a submites value using request as below:

HTML
<input type="text" id="turma_nome" name="turma[nome]" required="required" maxlength="10">

PHP
$request->get('turma[nome]')

But it doesn’t work.
How can i request do it please?

Source: Symfony Questions

LEAVE A COMMENT