I'm currently learning to script some facebook applications and some parts of the code of my book don't work coz of the constantly updating facebook dev php and javascript sdk!
My example app works like this: it selects one of the friends randomly, shows a pic and writes the name. Then it shall pop up a feed dialogue box to give the user the opportunity to post it on his wall.
This is the code i have been using (which does not work, the other stuff works perfectly):
$(document).ready(function() {
FB.ui({
method: 'feed',
name: 'App Name',
link: 'http://apps.facebook.com/[your_app_url]/',
picture: 'http://yourwebsite.com/images/app.PNG',
caption: 'My App Caption',
description: 'Today\'s blahblah is
<?php echo $random_friend['name']; ?>.',
message: 'check out this name
<?php echo $random_friend['name']; ?>.',
to: '<?php echo $random_friend['id']; ?>'
},
please consider and keep in mind that i'm new to Javascript and Php so i'm learning both in combination with facebook app developement :)
Thanx guys.