Using CURL liberary in php The curl liberary in php is very powerfull liberary to get the remote sarver result. Example:s you can get facebook users photo, google map, gmail, and various webservice. Code of curl liberary using basic: <?php $sturl ="http://localhost/post.php"; $ch = curl_init($sturl); //start initial curl curl_setopt($ch,CURLOPT_POST,true); //define method of data transfer curl_setopt($ch,CURLOPT_POSTFIELDS,$data); //post field curl_setopt($ch,CURLOPT_RETURNTRANSFER,true); //get the result in a variable array curl_setopt($ch,CURLOPT_TIMEOUT,10); //time out processing $res = curl_exec($ch); //execute the curl and store in a variable $res $resinfo = curl_getinfo($ch); //get the curl ingormation curl_close($ch); //close the curl process var_dump($res); //dumping the result ?> Example code to get facebook user photo: <?php $facebook_uid = md.mahediazad; //faebook user id $sourcecode = save_facebook_profile_photo($facebook_uid); print_r($sourcecode); fil