<?php
$ch = curl_init(); //curl handler init
curl_setopt($ch,CURLOPT_URL,"http://www.google.com/search?q=curl");
curl_setopt($ch,CURLOPT_RETURNTRANSFER,true);// set optional params
curl_setopt($ch,CURLOPT_HEADER, false);
$result=curl_exec($ch);
...