views:

53

answers:

0

Background info: I would like to implement a simple commenting mechanism, where people use Facebook Connect to login. I am only saving the uid of users, a date, and some text for every record.

Problem: How can I display the names of users, from the server side, not using Javascript, when the visitor is not logged in?? Is there a way to login to a temporary account (say the developer) and display the names? or even more info, like the network those users belong to?

Some code: The following is called before any Facebook related statement: api = new facebook.API(); try { api.ApplicationKey = Utility.ApiKey(); api.SessionKey = Utility.SessionKey(); api.Secret = Utility.SecretKey(); }

the UIDs are retrieved later from a database: foreach row { api.uid = Convert.ToInt32(dr["uid"].ToString()); dr["Name"] = api.users.getInfo().name;

Tools: I use Nikhilk's 'Facebook .NET' framework (found here: http://www.nikhilk.net/FacebookNET.aspx)