Ok i tried to search my feed but I'm not getting through
http://www.triniscene.com/tsv7/search/google_search.php?q=tribe
Now i'm running into a problem with the following code
----------------------------------------
function getResultArray($id, $site, $url) {
// Get the parameters:
$params = "v=1.0&key=".
$id."&rsz=large&cx=013450582310886895864:xmmgnnzezay";
$params1 = sprintf("%s&q=%s",$params, urlencode("site:http://
triniscene.com/tsv7 filetype:xml ".$_GET['p']));
$params2 = sprintf("%s&q=%s",$params, urlencode("site:http://
video.triniscene.com ".$_GET['p']));
$data = '';
/*// Include the library:
include_once("../includes/nusoap/lib/nusoap.php");
// Create a instance of the SOAP client object
$soapclient = new soapclient($baseurl);
$data = $soapclient->call("doGoogleSearch", $params,
"urn:GoogleSearch", "urn:GoogleSearch"); */
$ch_web = curl_init();
$ch_video = curl_init();
curl_setopt($ch_web, CURLOPT_URL,
'http://ajax.googleapis.com/ajax/
services/search/blogs?'. $params1);
curl_setopt($ch_video, CURLOPT_URL,
'http://ajax.googleapis.com/ajax/
services/search/web?'. $params2);
curl_setopt($ch_web, CURLOPT_HEADER, 0);
curl_setopt($ch_video, CURLOPT_HEADER, 0);
curl_setopt($ch_web, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch_video, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch_video, CURLOPT_REFERER,
'http://www.triniscene.com/
tsv7/search/google_search.php');
curl_setopt($ch_web, CURLOPT_REFERER,
'http://www.triniscene.com/
tsv7/search/google_search.php');
//$data = curl_exec($ch_web);
//curl_close($ch_web);
//create the multiple cURL handle
$mh = curl_multi_init();
//add the two handles
curl_multi_add_handle($mh,$ch_web);
curl_multi_add_handle($mh,$ch_video);
$running=NULL;
//execute the handles
do {
curl_multi_exec($mh,$running);
} while ($running > 0);
$data = curl_multi_getcontent($ch_web);
$data .= curl_multi_getcontent($ch_video);
//close the handles
curl_multi_remove_handle($mh,$ch_web);
curl_multi_remove_handle($mh,$ch_video);
curl_multi_close($mh);
echo "<pre>".$data."<pre>";
return $data;
}
--------------------------------------
I'm trying to run the curl_multi_getcontent but the API is only
returning "one" of the handles...with the last handle returning a null
200 response...now if i were to reverse the handles the same thing
happens...
Is it that I have exhausted the amount of returned results from the
first handle?
On Aug 27, 8:42 pm, "[EMAIL PROTECTED]"
<[EMAIL PROTECTED]> wrote:
> I meant the google seach api...can it search atom feeds from a site
>
> On Aug 27, 8:41 pm, "[EMAIL PROTECTED]"
>
> <[EMAIL PROTECTED]> wrote:
> > Can google api search xml content or atom feeds?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google AJAX API" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/Google-AJAX-Search-API?hl=en
-~----------~----~----~----~------~----~------~--~---