Türkiye'nin En Eski Webmaster Forumu İyinet'e Hoşgeldiniz!

google index ve backlink

xmcdeltat

0
Onaylı Üye
Üye
Katılım
3 Temmuz 2010
Mesajlar
0
Açılan Konu
7
Tepki puanı
0
Kod:
/* [B]Google Backlink Sorgu[/B] */
        
        
    function google_backlink_islem($uri)
        {
        $uri = trim(eregi_replace('http://', '', $uri)); $uri = trim(eregi_replace('http', '', $uri));
        $url = 'http://www.google.com/search?q=en&lr=&ie=UTF-8&q=link:'.$uri.'&filter=0';
        @$v = file_get_contents($url);
        preg_match("/<div id=resultStats>([A-Za-z]+ |)([0-9,]+) result/si",$v,$r);
        return ($r[2]) ? $r[2] : '0';
    }
    
    function google_backlink_sorgu($url)
    {
        return google_backlink_islem($url);
    }
    
  [B]  // GOOGLE INDEX[/B]
    
    function google_indexed($uri)
        {
        $uri = trim(eregi_replace('http://', '', $uri)); $uri = trim(eregi_replace('http', '', $uri));
        $url = "http://www.google.com/search?q=link%3A".$domain;$file = file_get_contents($url); 
        $v = file_get_contents($url);
        preg_match("/<div id=resultStats>([A-Za-z]+ |)([0-9,]+) result/si",$v,$r);
        return ($r[2]) ? $r[2] : '0';
    }
    
    function google_index_sorgu($url)
    {
        return google_indexed($url);
    }

?>


bu kodlama çalışmıyor
google index ve backlink sayısını nasıl görebilirim scriptte yardım
 

xmcdeltat

0
Onaylı Üye
Üye
Katılım
3 Temmuz 2010
Mesajlar
0
Açılan Konu
7
Tepki puanı
0
google backlink sorgu

arkadaşlar google backlink sorguyu buldum ama bir sorun var arka arkaya sorgulama yapamıyorum

api key girmem gerekiyorum nereye ve nasıl bir kod eklerim bari bunu söyleyin yardımcı olabilicek biri yokmu. çünkü kendi kendime yazıyorum gibi geliyor :)

Kod:
/* Google Backlink Sorgu */
        
        
    function google_backlink_islem($uri)
        {
    $url="http://ajax.googleapis.com/ajax/services/search/web?v=1.0&q=link:".$uri."&filter=0";
$ch=curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_USERAGENT,$_SERVER['HTTP_USER_AGENT']);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt ($ch, CURLOPT_HEADER, 0);
curl_setopt ($ch, CURLOPT_NOBODY, 0);
curl_setopt($ch, CURLOPT_TIMEOUT, 30);
$json = curl_exec($ch);
curl_close($ch);
$data=json_decode($json,true);
if($data['responseStatus']==200)
return $data['responseData']['cursor']['resultCount'];
else
return false;
}    
    
    function google_backlink_sorgu($url)
    {
        return google_backlink_islem($url);
    }
 
Üst