note 88055 added to curl.examples-basic
| From: | cmnajs at gmail dot com | Date: | Wed, 07 Jan 2009 23:57:16 +0000 |
| Subject: | note 88055 added to curl.examples-basic | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-148933@lists.php.net to get a copy of this message | ||
Following code returns the curl output as a string.
<?
// create curl resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, "example.com");
//return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// $output contains the output string
$output = curl_exec($ch);
// close curl resource to free up system resources
curl_close($ch);
?>
----
Server IP: 69.147.83.197
Probable Submitter: 119.30.87.20
----
Manual Page -- http://www.php.net/manual/en/curl.examples-basic.php
Edit -- https://master.php.net/note/edit/88055
Del: integrated -- https://master.php.net/note/delete/88055/integrated
Del: useless -- https://master.php.net/note/delete/88055/useless
Del: bad code -- https://master.php.net/note/delete/88055/bad+code
Del: spam -- https://master.php.net/note/delete/88055/spam
Del: non-english -- https://master.php.net/note/delete/88055/non-english
Del: in docs -- https://master.php.net/note/delete/88055/in+docs
Del: other reasons-- https://master.php.net/note/delete/88055
Reject -- https://master.php.net/note/reject/88055
Search -- https://master.php.net/manage/user-notes.php