I am trying to make an application by getting all birthdays and other information from you facebook friends using php sdk facebook.
I get a list of friends and with the foreach cycle, I get all the information for each friend.
It all works, it only takes 4 minutes + to get all the information. (for each friend I have to make a new call)
I canβt expect users of my application to wait so long.
Is there a way to get information faster.
this is my code:
foreach ($arrFriends as $f => $value)
{
echo('
');
$fql = "select uid, email, name, hometown_location, sex, birthday, education, relationship_status, pic_square from user where uid=" . $value[id];
$param = array('method' => 'fql.query','query' => $fql,'callback' => '');
$friend = $facebook->api($param);
//dan opslaan in de database:
print_r($friend);
echo('
');
}
source
share