function curl_function($url){
$proxy = '127.0.0.1:8888';
$proxyauth = 'user:password';
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,$url);
curl_setopt($ch, CURLOPT_PROXY, $proxy);
curl_setopt($ch, CURLOPT_PROXYUSERPWD, $proxyauth);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_HEADER, 1);
$curl_scraped_page = curl_exec($ch);
curl_close($ch);
return $curl_scraped_page;
}
$url = 'http://www.baskasite.com';
$data = curl_function($url);Çekeceğiniz her şey veriler $data değişkenin içindedir.
Bu aşamadan sonra da preg_match_all fonksiyonuyla almak istediğiniz verileri ayıklayıp değişkenlere atayacaksınız, ardından bu verileri veritabanına insert edeceksiniz.