• 04-04-2010, 03:40:19
    #1
    Selamlar arkadaşlar.

    Ben google'a file_get_contents üzerinden "http://www.google.com/search?hl='.$dil.'&q='.$data.'&start=0" gibisinden bir sorgu gönderiyorum.

    Ancak bana;

    ForbiddenYour client does not have permission to get URL /search?hl=tr&q=akadal&start=0 from this server. (Client IP address: 94.102.11.112)
    
    Please see Google's Terms of Service posted at http://www.google.com/terms_of_service.html 
    
    If you believe that you have received this response in error, please report your problem. However, please make sure to take a look at our Terms of Service (http://www.google.com/terms_of_service.html). In your email, please send us the entire code displayed below. Please also send us any information you may know about how you are performing your Google searches-- for example, "I'm using the Opera browser on Linux to do searches from home. My Internet access is through a dial-up account I have with the FooCorp ISP." or "I'm using the Konqueror browser on Linux to search from my job at myFoo.com. My machine's IP address is 10.20.30.40, but all of myFoo's web traffic goes through some kind of proxy server whose IP address is 10.11.12.13." (If you don't know any information like this, that's OK. But this kind of information can help us track down problems, so please tell us what you can.)
    
    We will use all this information to diagnose the problem, and we'll hopefully have you back up and searching with Google again quickly!
    
    Please note that although we read all the email we receive, we are not always able to send a personal response to each and every email. So don't despair if you don't hear back from us!
    
    Also note that if you do not send us the entire code below, we will not be able to help you.
    
    Best wishes,
    The Google Team
    
    /+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/
    fyOC3rRy13Xzaj6Q7ZV6_p0EIBEdJXjPjzFYIxHKZk5dZe0U1
    _a1KHKh1novFUHZwMGcKSpW74nHYj881VeYnP9EwNsXjUpPHO
    y7iTskkZaA8BvJjCPZIvFidknrGxS_5mV9M6SCHb3Xymec2lr
    FGv4EbptXuIWsLWUVserJc2VN1_600hNUtPQ2LtEnHZqbi34i
    Nr08YT5xR6SaV1pAxApK2AHkWtSxnMYj1mLJCDMkTFioyFYss
    P5CMnFapctHqMNkOprc4kPcnExx__j5bBlW9-YCVlWtgwLblT
    GCvheQsp4KfGW9pchmf0PUy6rOfNn74QlZrwURTXicHnwqwuL
    zBLCQf09dvetFhuAu0qbW_tSJ6YszGxdMJxetREWDr60-R1pm
    DSWy8Ut0owWR3i9rxKzeowxXaUxTe6zylN_oZz_t83r2DOiQB
    2FOQ0NV1uL4uNmUmWRbGfFjQPK0R5eCdNh6o5QHQ-aofflu-7
    RPNVOAX7urN_Cf2l4OdwEtpCBJYXstrD8eHNqpbvvuDaJg4Zn
    pUVciVkLahyztvDCPM44ABzPt0A_Gph5Lmj8QBPuj65CZM_qX
    FHj9M4w3bb8pzTdK-3s9fjFrIRfKAqZ_Bo3cHTKDYFALi-dpQ
    o2LvgaHSlcV8s-HmhdpxpZbxrPJOmeTQPesKg5tzY7YA-VZiX
    OtxOofYc8b74wHdoybElt_BVmigcYNWeGadaE4P5VirT66h6_
    N2LqcJe-JaA8W04dT
    +/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+/+
    hatası döndü.

    Bunun nedenini veya çözümüyle ilgili fikir yürütecek arkadaş varsa akıl, fikir rica ediyorum. Anlayamadım gitti..
  • 04-04-2010, 04:55:36
    #2
    Buyur Bu Şekilde Kullan Muhtemelen file_get_contents 'i Yanlış Kullanıyorsun.


    $dil = "tr";
    $data = "mp3";
    $gel = file_get_contents("http://www.google.com/search?hl=$dil&q=$data&start=0");
    echo $gel;
  • 04-04-2010, 11:45:21
    #3
    Kimlik doğrulama veya yönetimden onay bekliyor.
    Google izin vermiyor sanırım file_get_contents()'e.
  • 04-04-2010, 12:19:59
    #4
    Curl ile yap,browser falan firefox yap,referansıda google.com yap olacaktır
  • 04-04-2010, 13:27:39
    #5
    file_get_contents i yanlış kullansam döndürdüğü hatayı alamazdım. Onda sorun yok da @tolgay007 nin dediği gibi geldi benim de aklıma REFERER falan kontrol ediyodur belki diye. Şu google özel aramayı kurcalayıp kendileri bişeyler yapanlar var bide onların yaptıklarına bakacam. Olmazsa cURL'e girişicem. Hiç de sevmedim şu cURL'ü ya.. Neyse çok teşekkür ederim fikirleriniz için.
  • 04-04-2010, 17:31:40
    #6
    akadal34 adlı üyeden alıntı: mesajı görüntüle
    file_get_contents i yanlış kullansam döndürdüğü hatayı alamazdım. Onda sorun yok da @tolgay007 nin dediği gibi geldi benim de aklıma REFERER falan kontrol ediyodur belki diye. Şu google özel aramayı kurcalayıp kendileri bişeyler yapanlar var bide onların yaptıklarına bakacam. Olmazsa cURL'e girişicem. Hiç de sevmedim şu cURL'ü ya.. Neyse çok teşekkür ederim fikirleriniz için.
    Al Ozaman Sana Curl

    <?php
    
    $dil = "tr";
    $data = "mp3"; 
    $ch = curl_init();
    curl_setopt($ch, CURLOPT_URL, "http://www.google.com/search?hl=".$dil."&q=".$data."&start=0");
    curl_setopt($ch, CURLOPT_HEADER, 0);
    curl_setopt($ch, CURLOPT_POST, 0);
    curl_setopt($ch, CURLOPT_REFERER, "http://www.google.com/");  
    curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
    
    $sonuc = curl_exec($ch) or die("Olmadı");
    curl_close($ch);
    
    
    echo $sonuc;
     
    
    
    ?>
    //Ayrıca bennim bi botta file_get_contents kullandım sorunsuz çalışıyor.Burda başka bir hata var.
  • 04-04-2010, 18:44:02
    #7
    @CoLLeR çok teşekkür ederim yardımın için, çok sağol. Dil karakter hatası var sonuç sayfasında, onu da kendim kurcalayarak halledicem artıkın
  • 04-04-2010, 18:55:51
    #8
    Dil de tamam. ben utf-8 kullanıyordum da google iso-8859-9 istiyomuş, hemen verdim istediğini
  • 04-04-2010, 19:51:28
    #9
    akadal34 adlı üyeden alıntı: mesajı görüntüle
    @CoLLeR çok teşekkür ederim yardımın için, çok sağol. Dil karakter hatası var sonuç sayfasında, onu da kendim kurcalayarak halledicem artıkın
    akadal34 adlı üyeden alıntı: mesajı görüntüle
    Dil de tamam. ben utf-8 kullanıyordum da google iso-8859-9 istiyomuş, hemen verdim istediğini
    Rica Ederim Hayırlı Olsun.