FBStreamDialog doesn't show attachment
I use the simple FBStreamDialog example in my iPad app:
FBStreamDialog* pDialog = [[[FBStreamDialog alloc] init] autorelease]; pDialog.delegate = self;
pDialog.userMessagePrompt = @"Example prompt"; pDialog.attachment = @"{\"name\":\"Facebook Connect for iPhone\",\"href\":\"http://developers.facebook.com/connect.php?tab=iphone\",\"caption\":\"Caption\",\"description\":\"Description\",\"media\":[{\"type\":\"image\",\"src\":\"http://img40.yfrog.com/img40/5914/iphoneconnectbtn.jpg\",\"href\":\"http://developers.facebook.com/connect.php?tab=iphone/\"}],\"properties\":{\"another link\":{\"text\":\"Facebook home page\",\"href\":\"http://www.facebook.com\"}}}";
NSLog(@"prompt: %@", pDialog.userMessagePrompt); NSLog(@"attachment: %@", pDialog.attachment);
[pDialog show];
NSLogs are OK.
开发者_StackOverflow社区 The problem is that neither message prompt nor attachment are shown in FBStreamDialog. Can anyone help?The problem was in simulator. It works on device.
精彩评论