views:

343

answers:

3

Is there a way to check if the user of an application has added a profile box for that application? This is possible because I have seen it on iLike where a window is shown on the main page to ask the user if he/she wants to add a profile box if the user hasn't done so already. Any help would be appreciated. If this is not possible with the API then how is this done in FBML?

Thank you in advance.

+1  A: 

There is no way you can tell if a user added your app to their profile. I'm not sure what iLike is doing on the backend, but it seems they prompt to post to your profile on install. By default, the profile has nothing, you need to post something to it.

Normally this is done by displaying a special button that Facebook displays if they don't have the application already in the profile. But Facebook also won't display the special button if the profile has no content. So it's a chicken and the egg scenario, which comes first?

You can query what is currently in the users profile (getProfileFBML), so you could possibly use this as a check to see if they have added your app to the profile. If it's empty, you never posted any content their. But you can't tell if they subsequently removed it, or moved it to the Boxes tab (which is useless).

Brent Baisley
A: 

I haven't used iLike, but the <fb:add-section-button section="profile" /> tag automatically disappears once the user clicks it and gives the app permission to post to their profile.

In my app, I always write something to the profile object each time the user updates the app - if they haven't given permission for the profile object to appear, it remains invisible. That's all.

Mike Heinz
A: 

no you cannot

natas