Hello,
is it possible to pre populate the buddy list without to user to be online?
I mean i have a pre owned buddy list ( mysql based ) and i wish to import it into SmartFox actual Buddy list ( Buddylist 2.0 ) so that when the user comes online he/she will find his/her buddylist already filled with the record from the html version buddy list.
Is it doable?
Thanks
Pre-populate Buddy List
after a lot of thinking i came up with something like this:
I run this inside a init() of an extension. I infact menaged to get the buddy list loaded but the first time i relog into the server all the buddy are empty.
Does this make any sense?
Code: Select all
a=_server.getCurrentZone();
var sql = "SELECT * FROM amici";
var queryRes = dbase.executeQuery(sql);
n=0;
for (var i = 0; i < queryRes.size(); i++)
{
var tempRow = queryRes.get(i)
utente=tempRow.getItem("utente");
buddy=tempRow.getItem("buddy");
a.addBuddy(utente, buddy);
n++;
}
trace("Buddy Importata per " + n + " utenti");Does this make any sense?