When using the methods for wall posts in the current Facebook sample app (in 2011.591), the options appear to be either:
-
Just post a message directly to their wall, without letting the user edit the wall post or even see what’s being posted (this is what’s going on in all of the tutorials and code snippets I found in the forums)
-
Give the user a blank dialog box to post whatever they want to their wall via your application.
If I understand the Facebook Platform Policies correctly (http://developers.facebook.com/policy/), you can’t post something to someone’s wall that they didn’t generate themselves. You can see in the feed dialog options page (http://developers.facebook.com/docs/reference/dialogs/feed/) that the option to even pre-fill the message was taken away on July 12, 2011.
So, I believe that the option provided in the Facebook sample app that posts the message “Posting from Corona SDK!” violates the Facebook Platform Policies. Also, if an app was posting a message to my facebook wall that I wasn’t even getting to see before it was posted, I wouldn’t be very happy about it.
The way I see it, the only way to let someone share your app on Facebook is to provide them with a blank dialog box from within your app and hope they say something nice.
Here is the code to do this:
local callFacebook = function()
local facebookListener = function( event )
if ( "session" == event.type ) then
if ( "login" == event.phase ) then
facebook.showDialog( {action="stream.publish"} )
end
end
end
facebook.login( "YOUR APP ID HERE", facebookListener, { "publish\_stream" } )
end
[import]uid: 63524 topic_id: 14770 reply_id: 314770[/import]