Currently, our app posts to users' friends' walls via Graph API. However, Facebook is deprecating this functionality so we are migrating to the Feed Dialog per Facebook's recommendations (see the February 6, 2013 section at https://developers.facebook.com/roadmap/).
Now, we know we can specify the recipient as part of the Javascript SDK call (note FB.init() is called elsewhere earlier on the page):
<p><a onclick="launchFeedDialog(); return false">Testing the Feed Dialog</a></p>
<script>
function launchFeedDialog() {
// calling the API ...
var obj = {
method: 'feed',
to: 'RECIPIENT NAME', // Can specify recipient here
link: 'http://example.com',
name: 'Test post',
description: 'Test description'
};
FB.ui(obj);
}
</script>
However, it does not seem like the user can modify the recipient in the launched dialog. A screenshot of what I mean is at http://i.imgur.com/oLPTO.png.
Is there some way of invoking the Feed Dialog so that the user can change/add recipients, like in the Send Dialog?
The flow we are trying to implement (and the way it currently is) is:
- User clicks a button to launch the Feed dialog
- User fills in the Feed dialog (including recipient) and submits
Right now, we are stuck with this awkward flow:
- User fills out a custom control specifying the recipient
- User clicks a button to launch the Feed dialog
- User fills in the Feed dialog and submits
OK, we found a workaround. The general idea:
display=iframe
)Some caveats/reasoning for above:
Here's a basic example using a simple text input:
You can find a screenshot of a slightly more fleshed out solution at: http://i.imgur.com/0jTM391.png