![]() |
|
||||
|
bildiğiniz gibi bazı free arama scriptleri var bi tanesini kurayım dedim.
google api key diye bişey sayyıklıyor. gittim indirdim google api 666 kb civarında http://www.google.com/apis/ burdan. yalnız bu indirdiğim yerde dosyalara baktım key filan görmedim. indirdiğim scriptin search.php sindede bunu istiyor şimdi. Kod:
// insert your google key here, if you don't have one http://www.google.com/apis/ (it's free) $yourGoogleKey = ""; // insert your website url here $yourWebsite = "http://www.phpgoogle.com"; //tamam buraya diyar.biz/arama yazdım diyar.biz/arama bu key nedir pek bişeyde çakmıyorum. hatta hiç bişey anlamıyorum desem daha doğru. herşey için teşekürler . şimdiden sağolun |
|
||||
|
http://www.fesih.com/arama/search.ph...hakan&www=true
verilen keyi doğru yazdığıma eminim. indirdiğim dosyaları yükledim. ama hata veriyor yukarıdaki gibi. search.php ekliyorum arkadaşlar hatam nerde acaba. Kod:
<?
// insert your google key here, if you don't have one http://www.google.com/apis/ (it's free)
$yourGoogleKey = "ABQIAAAA-Aa8glCvPcRQAk6NeImfqhTb0Hv0jTfXR8AD-fS5lBdEvN4p7RRNvHF3vwm-P7vP1t1nmXClcwFqXg";
// insert your website url here
$yourWebsite = "http://www.fesih.com/";
//----------------------------------------------------------------------------------------------
// build search query and connect to google
//----------------------------------------------------------------------------------------------
require_once("nusoap.php");
if($_GET) { extract($_GET, EXTR_PREFIX_SAME, "get_"); }
if($_POST) { extract($_POST, EXTR_PREFIX_SAME, "post_"); }
if ($yourGoogleKey == "ABQIAAAA-Aa8glCvPcRQAk6NeImfqhTb0Hv0jTfXR8AD-fS5lBdEvN4p7RRNvHF3vwm-P7vP1t1nmXClcwFqXg") {
echo "You didn't insert a Google Key Yet ! Get one at www.google.com/apis/ ..";
break;
}
if ($query && $www) {
$q = urldecode($query);
if ($www != "true") { $q.= " site:$www.fesih.com"; }
if(!$start) { $start=0; } else { $start = intval($start); }
$parameters = array(
"key" => $yourGoogleKey, // google developer key
"q" => $q, // search query
"start" => $start, // result start index
"maxResults" => 10, // 10 is the maximum
"filter" => false, // filtering similar entries
"restrict" => "", // country and topic restrictions
"safeSearch" => false, // adult content filter
"lr" => "", // language restrictions
"ie" => "ISO-8859-9", // deprecated and ignored parameter
"oe" => "ISO-8859-9" // deprecated and ignored parameter
);
$soapclient = new soapclient("http://api.google.com/search/beta2");
$result = $soapclient->call("doGoogleSearch", $parameters, "urn:GoogleSearch");
$begin = $start + 1;
$end = $start + $parameters["maxResults"];
$total = $result["estimatedTotalResultsCount"];
}
//----------------------------------------------------------------------------------------------
// html headers, stylesheet and search form
//----------------------------------------------------------------------------------------------
?>
<?php include("header_search.php");?>
<?
//----------------------------------------------------------------------------------------------
// display results table if a search has been done
//----------------------------------------------------------------------------------------------
if ($query && $www) {
echo "<table width=\"609\" cellspacing=\"0\" cellpadding=\"10\" border=\"0\">\n";
echo "<tr class=\"row\"><td width=\"90%\" class=\"row\"></td></tr>\n";
if ($total == 0){
echo "<tr><td class=\"alert\">Your search returned no results ..</td></tr>\n";
}
if ($total > 0) {
$result = $result["resultElements"];
for ($i = 0; $i < $parameters["maxResults"]; $i++) {
$element = $result[$i];
$url = $element["URL"];
$title = $element["title"];
$snippet = $element["snippet"];
if ($url != "") {
echo "<tr>\n";
echo "<td><span class='list'>".($i+$begin).".</span> <a href='$url' class='link'>$title</a><br><span class='gray_small'>$snippet</span><br><a href='$url' class='link_small'>$url</a></td></tr>\n";
}
}
}
echo "<tr><td><br>";
if($begin > 1) { echo "<a href=\"google.php?query=$query&www=$www&start=".($start - 10)."\">previous 10 results</a> | "; }
echo "showing $begin to $end of $total results";
if ($end < $total) { echo " | <a href=\"search.php?query=$query&www=$www&start=".($start + 10)."\">next 10 results</a>"; }
echo "</td></tr>\n";
echo "</table>";
}
//----------------------------------------------------------------------------------------------
// html credits and footer ||| PLEASE DO NOT REMOVE COPYRIGHTS, Thanks |||
//----------------------------------------------------------------------------------------------
?>
<?php include("footer_search.php");?>
|
|
||||
|
tamam arkadaşlar buldum. www.google.com/apis/. de üye olunca gönderiyormuş mailinze.
ne acayiptirki dün akşam üye olmama rağmen göndermemişti. yukarıda onursql ninde dediği googlenin maps keyleri için üyelikmiş. kısa bi sitem: eminimki sorunumu burda bir çok kişi biliyordu. ama nedense Türk webmasterlerinin bir birini çekememezlikleri olacakki (lafım hepsine değil. ama bir çoğumuz böyle). kimse bildiği bişeyi paylaşmıyor. |
|
||||
|
http://www.google.com/apis/
Bu saydafan arama apisi alabilirsin https://www.google.com/accounts/NewA....com/createkey Bosuna sitem etme ; eger biraz iyi baksan cok rahat nerden alındıgını gorurdun. Bura herkes elinden geldigince bildiklerini paylasır. Bende şimdi buldum nereden alındıgını 1 yıl once falan kullanmıstım yerini unutmusum googleda web api diye aratınca bu sayfaya cok kolay ulasabiliryorsun. Konu Senbul tarafından (2005-11-05 Saat 15:19 ) değiştirilmiştir.. |
![]() |
| Seçenekler | |
| Stil | |
|
|
Benzer Konular
|
||||
| Konu | Konuyu Başlatan | Forum | Cevaplar | Son Mesaj |
| Google hakkında bir makale... | Caesar | Google Adsense | 31 | 2006-07-11 09:34 |
| Google Güncellemesi Hakkında | UguG | Google Optimizasyon | 2 | 2006-01-19 08:46 |
| google kanal hakkında? | kenan56 | Google Adsense | 5 | 2005-08-15 15:05 |
| Google Adsense hakkında | The_Best | Google Adsense | 3 | 2004-12-17 18:23 |
| Google.com reklamları hakkında | Permission | Google Adsense | 11 | 2004-12-15 12:07 |