12 $body = new http\Message\Body;
13 $body->append("foobar");
15 $request = new http\Client\Request;
16 $request->setBody($body);
17 $request->setRequestMethod("POST");
18 $request->setRequestUrl("http://dev.iworks.at/ext-http/.print_request.php");
20 $client = new http\Client;
21 $client->recordHistory = true;
23 $client->enqueue($request)->send();
24 echo $client->getHistory()->toString(true);
26 $client->requeue($request)->send();
27 echo $client->getHistory()->toString(true);
33 POST /ext-http/.print_request.php HTTP/1.1
38 Content-Type: application/x-www-form-urlencoded
39 X-Original-Content-Length: 6
47 Content-Type: text/html
48 X-Original-Content-Length: 19
52 POST /ext-http/.print_request.php HTTP/1.1
57 Content-Type: application/x-www-form-urlencoded
58 X-Original-Content-Length: 6
66 Content-Type: text/html
67 X-Original-Content-Length: 19
71 POST /ext-http/.print_request.php HTTP/1.1
76 Content-Type: application/x-www-form-urlencoded
77 X-Original-Content-Length: 6
85 Content-Type: text/html
86 X-Original-Content-Length: 19