If you’re using the Javascript SDK to publish stories, show the content in the callback response when a user shares content successfully:
FB.ui(
{
method: 'feed',
name: 'Google',
link: 'http://www.google.com/',
picture: 'http://google.com/xyz.jpg',
caption: 'Google Logo',
description: 'Search away'
},
function(response) {
if (response && response.post_id) {
// YOUR CODE GOES HERE
// e.g.
$("#some_div").show();
}
});
Note: Make sure you have loaded the Facebook JS SDK and jQuery.
More about JS SDK here
solved Facebook & Jquery – Share to show [closed]