note 102042 added to book.curl
| From: | jeffmixpute at osu1 dot php dot net | Date: | Mon, 24 Jan 2011 23:30:16 +0000 |
| Subject: | note 102042 added to book.curl | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-176266@lists.php.net to get a copy of this message | ||
Little code for an movie data base:
<?php
$curl_get = curl_init();
$curl_post = curl_init();
$curl_delete = curl_init();
$url = "http://localhost/movieservice.php/Name";
$xml = "<psequence>\r\n
<stream>\r\n
<streamid>0</streamid>\r\n
<sequenceid>0</sequenceid>\r\n
<imputfile>/content/konfigurator/videos/pl/outl.ts</inputfile>\r\n";
curl_setopt($curl_get, CURLOPT_URL, $url);
curl_setopt($curl_post, CURLOPT_URL, $url);
curl_setopt($curl_delete, CURLOPT_URL, $url);
curl_setopt($curl_get, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl_post, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl_delete, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl_get, CURLOPT_HTTPGET, true);
curl_setopt($curl_post, CURLOPT_POST, true);
curl_setopt($curl_delete, CURLOPT_CUSTOMREQUEST, true);
curl_setopt($curl_post, CURLOPT_POSTFIELDS, $xml);
$data_get = curl_exec($curl_get);
$data_post = curl_exec($curl_post);
$data_delete = curl_exec($curl_delete);
curl_close($curl_get);
curl_close($curl_post);
curl_close($curl_delete);
?>
----
Server IP: 217.160.235.204
Probable Submitter: 217.88.90.14
----
Manual Page -- http://www.php.net/manual/en/book.curl.php
Edit -- https://master.php.net/note/edit/102042
Del: integrated -- https://master.php.net/note/delete/102042/integrated
Del: useless -- https://master.php.net/note/delete/102042/useless
Del: bad code -- https://master.php.net/note/delete/102042/bad+code
Del: spam -- https://master.php.net/note/delete/102042/spam
Del: non-english -- https://master.php.net/note/delete/102042/non-english
Del: in docs -- https://master.php.net/note/delete/102042/in+docs
Del: other reasons-- https://master.php.net/note/delete/102042
Reject -- https://master.php.net/note/reject/102042
Search -- https://master.php.net/manage/user-notes.php