我通过PUT方法和JSON格式发送参数(interseccion,calle,numero) . 我想在php(Symfony2)中使用 $this->request->request 但是当我执行var_dump时没有参数 . 但是,该参数仅在 "content": protected. 标记中

我正在发送 $this->request$this->request->request 的转储

enter image description here

在这种情况下,我如何从 "content": protected. 标签中检索参数(interseccion,calle,numero)?

object(Symfony \ Component \ HttpFoundation \ Request)#6(20){[“attributes”] => object(Symfony \ Component \ HttpFoundation \ ParameterBag)#9(1){[“parameters”:protected] => array (8){[“_controller”] => string(60)“MiCiudad \ MgpBundle \ Controller \ MgpController :: solicitudAction”[“_route”] => string(26)“miciudad_mgp_mgp_solicitud”[“_ lute_params”] => array( 0){} [“_template”] => string(15)“index.html.twig”[“_ method”] => object(Sensio \ Bundle \ FrameworkExtraBundle \ Configuration \ Method)#412(1){[“方法“:protected] => array(1){[0] => string(3)”PUT“}} [”_ template_vars“] => array(0){} [”_template_streamable“] => bool(false)[ “_template_default_vars”] => array(0){}}} [“request”] => object(Symfony \ Component \ HttpFoundation \ ParameterBag)#7(1){[“parameters”:protected] => array(0) {}} [“query”] => object(Symfony \ Component \ HttpFoundation \ ParameterBag)#8(1){[“parameters”:protected] => array(2){[“apiKey”] => string(8 )“MiCiudad”[“hash”] => string(32)“e8e9beb0f0a2dd4800929566d13d2ce2”}} [“服务r“] => object(Symfony \ Component \ HttpFoundation \ ServerBag)#12(1){[”parameters“:protected] => array(44){[”MIBDIRS“] => string(24)”C:/ xampp / php / extras / mibs“[”MYSQL_HOME“] => string(16)”\ xampp \ mysql \ bin“[”OPENSSL_CONF“] => string(31)”C:/ xampp / apache / bin / openssl . cnf“[”PHP_PEAR_SYSCONF_DIR“] => string(10)”\ xampp \ php“[”PHPRC“] => string(10)”\ xampp \ php“[”TMP“] => string(10)”\ xampp \ tmp“[”HTTP_HOST“] => string(14)”miciudad.local“[”HTTP_CONNECTION“] => string(10)”keep-alive“[”CONTENT_LENGTH“] => string(4)”1238“[ “HTTP_ORIGIN”] => string(51)“chrome-extension:// hgmloofddffdnphfgcellkdfbfbjeloo”[“HTTP_USER_AGENT”] => string(108)“Mozilla / 5.0(Windows NT 6.1; WOW64)AppleWebKit / 537.36(KHTML,与Gecko一样)Chrome / 29.0.1547.76 Safari / 537.36“[”CONTENT_TYPE“] => string(16)”application / json“[”HTTP_ACCEPT“] => string(3)”/“ [“HTTP_ACCEPT_ENCODING”] => string(17)“gzip,deflate,sdch”[“HTTP_ACCEPT_LANGUAGE”] => string(15)“es-419,es; q = 0.8”[“PATH”] => string(397 )“C:\ Windows \ system32; C:\ Windows; C:\ Windows \ System32 \ Wbem;%SSTEMROOT%\ System32 \ WindowsPowerShell \ v1.0 \ C:\ Program Files \ Java \ jdk1.7.0_03 \ bin; C:\ xampp \ php ; C:\ Program Files(x86)\ Git \ bin; C:\ ProgramData \ Composer \ bin ;; C:\ Windows \ System32 \ WindowsPowerShell \ v1.0 ; C:\ Program Files (x86)\ QuickTime \ QTSystem ; C:\ Program Files \ SlikSvn \ bin; C:\ Windows \ System32 \ WindowsPowerShell \ v1.0 ; C:\ Program Files \ nodejs ;“[”SystemRoot“] => string(10)“C:\ Windows”[“COMSPEC”] => string(27)“C:\ Windows \ system32 \ cmd.exe”[“PATHEXT”] => string(53)“ . COM; .EXE ; .BAT; .CMD; .VBS; .VBE; .JS; .JSE; .WSF; .WSH; .MSC“[”WINDIR“] => string(10)”C:\ Windows“[”SERVER_SIGNATURE“] => string(98)“Apache / 2.4.3(Win32)OpenSSL / 1.0.1c PHP / 5.4.7服务r at miciudad.local端口80“[”SERVER_SOFTWARE“] => string(45)”Apache / 2.4.3(Win32)OpenSSL / 1.0.1c PHP / 5.4.7“[”SERVER_NAME“] => string(14) “miciudad.local”[“SERVER_ADDR”] => string(9)“127.0.0.1”[“SERVER_PORT”] => string(2)“80”[“REMOTE_ADDR”] => string(9)“127.0.0.1 “[”DOCUMENT_ROOT“] => string(32)”C:/ xampp / htdocs / miCiudad-Web / web“[”REQUEST_SCHEME“] => string(4)”http“[”CONTEXT_PREFIX“] => string(0 )“”[“CONTEXT_DOCUMENT_ROOT”] => string(32)“C:/ xampp / htdocs / miCiudad-Web / web”[“SERVER_ADMIN”] => string(19)“admin@localhost.com”[“SCRIPT_FILENAME” ] => string(44)“C:/xampp/htdocs/miCiudad-Web/web/app_dev.php”[“REMOTE_PORT”] => string(5)“50953”[“GATEWAY_INTERFACE”] => string(7) “CGI / 1.1”[“SERVER_PROTOCOL”] => string(8)“HTTP / 1.1”[“REQUEST_METHOD”] => string(3)“PUT”[“QUERY_STRING”] => string(53)“apiKey = MiCiudad&hash = e8e9beb0f0a2dd4800929566d13d2ce2“[”REQUEST_URI“] => string(80)”/ app_dev.php/mgp/solicitud?apiKey=MiCiudad&hash=e8e9beb0f0a2dd4800929566d13d2ce2“[”SCRIPT_NAME“] => string(12) “/app_dev.php”[“PATH_INFO”] => string(14)“/ mgp / solicitud”[“PATH_TRANSLATED”] => string(27)“redirect:\ app.php \ solicitud”[“PHP_SELF”] = > string(26)“/ app_dev.php/mgp/solicitud”[“REQUEST_TIME_FLOAT”] => float(1380716540.164)[“REQUEST_TIME”] => int(1380716540)}} [“files”] => object(Symfony \ Component \ HttpFoundation \ FileBag)#11(1){[“parameters”:protected] => array(0){}} [“cookies”] => object(Symfony \ Component \ HttpFoundation \ ParameterBag)#10(1) {[“parameters”:protected] => array(0){}} [“headers”] => object(Symfony \ Component \ HttpFoundation \ HeaderBag)#13(2){[“headers”:protected] => array (10){[“host”] => array(1){[0] => string(14)“miciudad.local”} [“connection”] => array(1){[0] => string( 10)“keep-alive”} [“content-length”] => array(1){[0] => string(4)“1238”} [“origin”] => array(1){[0] =>字符串(51)“chrome-extension:// hgmloofddffdnphfgcellkdfbfbjeloo”} [“user-agent”] => array(1){[0] => string(108)“Mozilla / 5.0(Windows NT 6.1; WOW64)AppleWebKit / 537.36(KHTML,像Gecko)Chrome / 29.0.1547.76 Safari / 537.36“} [”content-type“] => array(1){[0] => string(16)”application / json“} [”accept“] => array (1){[0] => string(3)“/”} [“accept-encoding”] => array(1){[0] => string(17)“gzip,deflate,sdch”} [“ accept-language“] => array(1){[0] => string(15)”es-419,es; q = 0.8“} [”x-php-ob-level“] => array(1) {[0] => int(1)}} [“cacheControl”:protected] => array(0){}} [“content”:protected] => string(1238)“{”interseccion“=”LA RIOJA “,”calleCorregida“:”LA RIOJA“,”numeroCorregido“:”3800“,”direccionValidada“:1,”tipoSolicitudId“:”8“,”datos_extendidos“:{},”idioma“:”es“,”descripcion “:” “ ”datos_personales“:{ ”telefono“: ”0201AB1FAFC5E521C3AD003D7BBBE809D13EFBB5936BF2F11B471160699ADA15FF34B0CBD8D6281E5CC04D8DF9270E21EA831D571EF4C198FA6FC85D50E7D75FE2CC8E6F00FDFBFE58A594369C33BBB5261C“, ”apellido“:” 020129C5BEA 971F8980B95F4058485EDEC79C3DC5D2393DBBB5D18857EF1685363839B81B5F5B0BADFCCD2E31E254F9270FC5DE7D81917FABD985222014DFA87FE495E23A3964B215976749B4811C9464EB1" , “农布雷”: “0201BFF9E505FCF6DD4E0697EE1B888D4862740A6AFBFEDF0AC0ED98E733245EE8B926EF2FEBCD7D0DD94818FDDDE7C13347BED4E5ED93D5D6DFF98A18D93A2C77808B2CE58EB8CE8FB45651B9CE77E2F89B”, “电子邮件”: “020163DCA47AF4EF8A3A654BBBE80C9678A8757B908CCECBBCFEE1445977B21A534391F7B392BA14B7FCC026FFFB384A14DAB65FB6E09B14183B8E9D379666D9964B01C42BC2E10425007DD8C7209EF34CB2E5873082522BDCDED2955B800BCCB2E3”, “DNI”: “0201635402DDF67E1EBCAE620B2EE713719B687904BA111462FA998424E78BA310C0D8ED04071118215B47B25BA1D9C730398C16F62BB888C7F26591BC3D2E518D24CF325F41CD0386D9B172241DC4500CDD”}, “calleId”: “00691”, “latitud”: “ - 38.0149720701376”, “dispositivoId”:” 476“,”longitudinal“:” - 57.565044058572“,”foto“:”“,”calle“:”FORMOSA“}”[“languages”:protected] => array(2){[0] => string(6 )“es_419”1 => string(2)“es”} [“charsets”:protected] => NULL [“acceptableContentTypes”:protected] => NULL [ “pathInfo”:protected] => string(14)“/ mgp / solicitud”[“requestUri”:protected] => string(80)“/ app_dev.php/mgp/solicitud?apiKey=MiCiudad&hash=e8e9beb0f0a2dd4800929566d13d2ce2”[“baseUrl “:protected] => string(12)”/ app_dev.php“[”basePath“:protected] => NULL [”method“:protected] => string(3)”PUT“[”format“:protected] = > string(4)“html”[“session”:protected] => object(Symfony \ Component \ HttpFoundation \ Session \ Session)#99(3){[“storage”:protected] => object(Symfony \ Component \ HttpFoundation \ Session \ Storage \ NativeSessionStorage)#98(5){[“bags”:protected] => array(2){[“attributes”] => object(Symfony \ Component \ HttpFoundation \ Session \ Attribute \ AttributeBag)# 94(3){[“name”:“Symfony \ Component \ HttpFoundation \ Session \ Attribute \ AttributeBag”:private] => string(10)“attributes”[“storageKey”:“Symfony \ Component \ HttpFoundation \ Session \ Attribute \ AttributeBag“:private] => string(15)”_ sf2_attributes“[”attributes“:protected] => array(0){}} [”flashes“] => object(Symfony \ Component \ HttpFoundation \ Session \ Flas h \ FlashBag)#93(3){[“name”:“Symfony \ Component \ HttpFoundation \ Session \ Flash \ FlashBag”:private] => string(7)“闪烁”[“闪烁”:“Symfony \ Component \ HttpFoundation \ Session \ Flash \ FlashBag“:private] => array(0){} [”storageKey“:”Symfony \ Component \ HttpFoundation \ Session \ Flash \ FlashBag“:private] => string(12)”_ sf2_flashes“} } [“started”:protected] => bool(false)[“closed”:protected] => bool(false)[“saveHandler”:protected] => object(Symfony \ Component \ HttpFoundation \ Session \ Storage \ Proxy \ SessionHandlerProxy)#95(4){[“handler”:protected] => object(Symfony \ Component \ HttpFoundation \ Session \ Storage \ Handler \ NativeFileSessionHandler)#97(0){} [“wrapper”:protected] => bool (true)[“active”:protected] => bool(false)[“saveHandlerName”:protected] => string(5)“files”} [“metadataBag”:protected] => object(Symfony \ Component \ HttpFoundation \ Session \ Storage \ MetadataBag)#96(4){[“name”:“Symfony \ Component \ HttpFoundation \ Session \ Storage \ MetadataBag”:private] => string(10)“__ metadata”[“storageKey”:“Symfony \ COM ponent \ HttpFoundation \ Session \ Storage \ MetadataBag“:private] => string(9)”_ sf2_meta“[”meta“:protected] => array(3){[”c“] => int(0)[”u “] => int(0)[”l“] => int(0)} [”lastUsed“:”Symfony \ Component \ HttpFoundation \ Session \ Storage \ MetadataBag“:private] => NULL}} [”flashName“ :“Symfony \ Component \ HttpFoundation \ Session \ Session”:private] => string(7)“flashes”[“attributeName”:“Symfony \ Component \ HttpFoundation \ Session \ Session”:private] => string(10)“ attributes“} [”locale“:protected] => string(6)”es_419“[”defaultLocale“:protected] => string(2)”es“}

$this->request->request

object(Symfony \ Component \ HttpFoundation \ ParameterBag)#7(1){[“parameters”:protected] => array(0){}}