diff --git a/README.md b/README.md index ccb06b6..2561c86 100644 --- a/README.md +++ b/README.md @@ -90,10 +90,10 @@ $curl->delete('http://api.example.com/user/', array( ``` ```php -// Enable gzip compression. +// Enable gzip compression and download a file. $curl = new Curl(); $curl->setOpt(CURLOPT_ENCODING , 'gzip'); -$curl->get('https://www.example.com/image.png'); +$curl->download('https://www.example.com/image.png', '/tmp/myimage.png'); ``` ```php diff --git a/examples/google_maps_geocode_address.php b/examples/google_maps_geocode_address.php index 406c15c..7d40f49 100644 --- a/examples/google_maps_geocode_address.php +++ b/examples/google_maps_geocode_address.php @@ -3,7 +3,6 @@ require '../src/Curl/Curl.php'; use \Curl\Curl; - $address = 'Paris, France'; $curl = new Curl(); $curl->get('http://maps.googleapis.com/maps/api/geocode/json', array( diff --git a/examples/youtube_list_playlist_videos.php b/examples/youtube_list_playlist_videos.php index d51c896..45f781c 100644 --- a/examples/youtube_list_playlist_videos.php +++ b/examples/youtube_list_playlist_videos.php @@ -3,7 +3,6 @@ require '../src/Curl/Curl.php'; use \Curl\Curl; - define('YOUTUBE_API_KEY', 'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'); $playlistId = 'RDHJb0VYVtaNc';