X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;f=docs%2Fexamples%2FGET_Queries.php;fp=docs%2Fexamples%2FGET_Queries.php;h=cb21cb6de2bbd085ca8a2622f3a034bf7b36f967;hb=b562e34cf4f8c8fae7b8fe773e0eed71592b09c2;hp=0000000000000000000000000000000000000000;hpb=b1d7d87f91b5cdcf321cb103e1a315f639885d61;p=m6w6%2Fext-http diff --git a/docs/examples/GET_Queries.php b/docs/examples/GET_Queries.php new file mode 100644 index 0000000..cb21cb6 --- /dev/null +++ b/docs/examples/GET_Queries.php @@ -0,0 +1,23 @@ +setOptions( + array( 'cookiestore' => '../cookies/google.txt', + ) +); + +$r->setQueryData( + array( 'q' => '+"pecl_http" -msg -cvs -list', + 'hl' => 'de' + ) +); + +// HttpRequest::send() returns an HttpMessage object +// of type HttpMessage::RESPONSE or throws an exception +try { + print $r->send()->getBody(); +} catch (HttpException $e) { + print $e; +} +?>