Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
43 lines (33 sloc) 1.79 KB


MJFBWrapper is an FBConnect wrapper for the iPhone which makes it easier to post messages to the Facebook Wall. It also includes support for ImageShack when you want to post messages containing images.

Adding MJFBWrapper to your project

  1. Download and install FBConnect, instructions and download link
  2. Download the latest code version from the repository.
  3. Extract the archive.
  4. Open the project in Xcode.
  5. Drag and drop the ImageShack and MJFBWrapper groups to your classes group (in the Groups & Files view).
  6. Make sure to select Copy items when asked.

Code Example

This example takes care of the whole connect and permission process on Facebook.

FBSession *session = [FBSession sessionForApplication:kAPIKey secret:kAPISecret delegate:self];
[session resume];

MJFBStreamAttachment *attachment = [[[MJFBStreamAttachment alloc]init] autorelease];
attachment.message = @"Message"; = @"Name";
attachment.description = @"Description";
attachment.href = @"";
attachment.caption = @"Caption"
attachment.actionLink = [MJFBActionLink linkWithText:@"action" href:@""];
[ addObject:[MJFBAttachmentProperty propertyWithName:@"aName" text:@"text" href:@""]];

MJFBStream *fbStream = [[MJFBStream alloc] initWithFBSession:session delegate:self];	
[fbStream publishAttachment:attachment];
[fbStream release];


The project contains a simple demo which should give you an idea on how to use it. Add your Facebook API key and secret in MJFBWrapperAppDelegate.m build and run to try it out. See MJFBWrapperAppDelegate.m for the demo code.