After logged in to Facebook, we can post message to the logged in user account with hyperlink. Try the following code.
<html>
<head>
<title>My Facebook Login Page</title>
<script type="text/javascript">
function postToWall() {
var params = {};
params['message'] = 'Visit Eureka! - https://ykyuen.wordpress.com';
params['name'] = 'Eureka!';
params['link'] = 'https://ykyuen.wordpress.com';
params['picture'] = 'http://1.gravatar.com/blavatar/9c99f3c76686bf5edf1ea460356f00f2?s=128&ts=1321625806';
params['description'] = 'Hope my posts are useful to you. =)';
FB.api('/me/feed', 'post', params, function(response) {
if (!response || response.error) {
alert('Error occured');
} else {
alert('Post ID: ' + response.id);
}
});
}
</script>
</head>
<body>
<div id="fb-root"></div>
<script src="http://connect.facebook.net/en_US/all.js"></script>
<script>
FB.init({
appId:<fbapp-id>, cookie:true,
status:true, xfbml:true
});
</script>
<fb:login-button perms="publish_stream">Login with Facebook</fb:login-button>
<a href="javascript:postToWall()">Post To Wall</a>
</body>
</html>
Replace the fbapp-id with yours and try it out. you will get the following wall post.

Done =)
Reference: Facebook Developers – Facebook FB.api post how to specify a link target

Yes, your posts are very useful to us… keep up the good work…
LikeLike
Thanks for your comments Shashi. =)
LikeLike
yes very usefull
LikeLike
You are welcome~ =)
LikeLike
can this process allow other fb user than the admin of the app to post on their wall????
LikeLike
I think should be ok if your app setting allow post to wall. But please refer to the latest FB SDK documentation becoz the solution in this article is most likely outdated.
LikeLike