i was trying to get the gender of the person, but received a lot of
diferent errors. Im not sure that im using it right.
this is my code
function init(){
var params = {};
params[opensocial.DataRequest.PeopleRequestFields.PROFILE_DETAILS] =
[opensocial.Person.Field.GENDER];
var req = opensocial.newDataRequest();
req.add(req.newFetchPeopleRequest('VIEWER_FRIENDS', params),
'viewer_friends');
req.send(showFriends);
}
function showFriends(data){
friends = data.get('viewer_friends').getData();
html = new Array();
friends.each(function(person){
html.push(person.getDisplayName());
html.push(' - ');
html.push(person.getField(opensocial.Person.Field.GENDER).getKey()) ;
html.push('<br>');
});
alert('');
document.getElementById('content_div').innerHTML =
html.join('');
}
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Orkut Developer Forum" 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/opensocial-orkut?hl=en
-~----------~----~----~----~------~----~------~--~---