I am developing a Facebook Application and I want to present information to users if their friends are also using the application.
I found I way to get the user’s friends that are using the application in the following format:
[
{
"uid":1234,
"name":"Friend Name1",
"is_app_user":true
},
{
"uid":12345,
"name":"Friend Name 2",
"is_app_user":true
}
]
I only need an array with the UIDs to query my user database. Can someone provide an efficient example on how to prepare the above JSON Object?
I want to be able to use:
User.find_all_by_uid( uids )
Thanks
This should get you on your way.
do:
Check: http://flori.github.com/json/ for details
Here is the example you requested that gives you array of ids:
Hope that helps!