symfony - Sending a simple POST request from a controller symfony2 without cUrl -


i think there quite easy answer but, tried send post request rest api controller :

use symfony\component\httpfoundation\request;

...

$request = request::create('127.0.0.1', 'post', array('test' => 'this test'));

but did nothing, there missing send or execute method ? lot

by doing so, you're creating request object. no actual request sent out.

to suggest use: buzz

ultimately, may use sensiobuzzbundle in order have buzz service

edit:

forgot mention: believe buzz uses curl


Comments

Popular posts from this blog

How has firefox/gecko HTML+CSS rendering changed in version 38? -

javascript - Complex json ng-repeat -

jquery - Cloning of rows and columns from the old table into the new with colSpan and rowSpan -