Hi,
I’m implementing the facebook-plugin right now and therefore i have a question. In our case we want to have one button in our main menu, where the user can share on his wall that he’s playing crazyElephant.
I know that the following code is missing some if/else-statements, but I think it should work, when i press the button for the first time. So i want that the user connects to FB and without another button-click can share the post.
But with this code, unfortunately the user can just connect to FB and then returns to the app, without being able to post.
function postToUsersWall() {
//if not connected
facebook.openSession();
//if connected, just the following code
facebook.openWallDialog( {
"link" : "https://play.google.com/store/apps/details?id=xom.xxmassdeveloper.CrazyElephant&hl=de",
"description" : "Download this awesome game for android!",
"name" : "Crazy Elephant",
"caption" : "by X.X MassDeveloper",
} );
}
Is there a possibility, to combine this logic with a single button, so that the user can always share with one click, even if he wasn’t connected? Or is it only possible to connect before (e.g. with a dialogue that opens on the 5th app-start) and then get rid of the facebook.openSession() in this function?