Hi Ben,
I¹ve tried all posibilities I could think of, could you give me some
gidance, please?
<?php if ($sr['phoneNumbers']) { echo "phone Numbers:
".$sr['phoneNumbers'][number][0]."<br>"; } ?> <?php if
($sr['phoneNumbers']) { echo "phone Numbers:
".$sr['phoneNumbers'][number][1]."<br>"; } ?> <?php if
($sr['phoneNumbers']) { echo "phone Numbers:
".$sr['phoneNumbers'][main][number][0]."<br>"; } ?> <?php if
($sr['phoneNumbers']) { echo "phone Numbers:
".$sr['phoneNumbers'][main][number][1]."<br>"; } ?> <?php if
($sr['phoneNumbers']) { echo "phone Numbers:
".$sr['phoneNumbers'][fax][number][0]."<br>"; } ?> <?php if
($sr['phoneNumbers']) { echo "phone Numbers:
".$sr['phoneNumbers'][fax][number][1]."<br>"; } ?>
Thanks,
Sebastian
On 20/03/09 17:41, "Ben Lisbakken" <[email protected]> wrote:
> Hi Sebastian --
>
> I suggest you read through the documentation. All of the answers are in there
> :)
>
> Here is the reference to the result object:
> http://code.google.com/apis/ajaxsearch/documentation/reference.html#_class_Glo
> calResult
>
> -Ben
>
> On Fri, Mar 20, 2009 at 3:53 AM, sebastian de comocomo
> <[email protected]> wrote:
>> Thanks Ben,
>>
>> I managed to make work the addressLine Array, but not the Phone, what is the
>> format?
>>
>> $search_results['results'][$i]['phoneNumbers'] = $r->phoneNumbers;
>> $search_results['results'][$i]['type'] = $r->type;
>> $search_results['results'][$i]['number'] = $r->number;
>> $search_results['results'][$i]['addressLines'] = $r->addressLines;
>>
>> ...
>>
>> <?php if ($sr['phoneNumbers']) { echo "phone Number 0:
>> ".$sr['phoneNumbers']['main']['number'][0]."<br>"; } ?> <?php
>> if ($sr['addressLines']) { echo $sr['addressLines'][0]."<- address 1<br>"; }
>> ?> <?php if ($sr['addressLines']) { echo
>> $sr['addressLines'][1]."<- address 2<br>"; } ?>
>>
>> What is the format for the phone Array?
>>
>> I tried many combinations with these:
>>
>> .phoneNumbers[]
>> Supplies an array of phone number objects where each object contains a .type
>> property and a .number property. The value of the .type property can be one
>> of "main", "fax", "mobile", "data", or "".
>>
>> Thanks,
>>
>> Sebastian
>>
>>
>>
>>
>>
>> On 19/03/09 23:08, "Ben Lisbakken" <[email protected]
>> <http://[email protected]> > wrote:
>>
>>> Sure Sebastian --
>>>
>>> Take a look at this:
>>> http://code.google.com/apis/ajaxsearch/documentation/#fonje_snippets
>>>
>>> -Ben
>>>
>>> On Wed, Mar 18, 2009 at 3:25 AM, Sebastian <[email protected]
>>> <http://[email protected]> > wrote:
>>>>
>>>> Hi Ben & Insub2,
>>>>
>>>> How do we get so many fields from the API? are there any examples of
>>>> PHP & JSON that do so?
>>>>
>>>> Thanks,
>>>>
>>>> Sebastian
>>>>
>>>>
>>>>
>>>> On Mar 6, 1:27 am, Ben Lisbakken <[email protected]
>>>> <http://[email protected]> > wrote:
>>>>> > Where are you finding maxAge?
>>>>> > -Ben
>>>>> >
>>>>> > On Thu, Mar 5, 2009 at 3:00 PM, insub2 <[email protected]
>>>>> <http://[email protected]> > wrote:
>>>>> >
>>>>>> > > I can't find any documentation on what maxAge is for. Can anyone
>>>>>> tell
>>>>>> > > me?
>>>>
>>>
>>>
>>>
>>>
>>
>>
>
>
> >
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google AJAX APIs" 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
-~----------~----~----~----~------~----~------~--~---