Book Image

Flash Facebook Cookbook

By : James Ford
Book Image

Flash Facebook Cookbook

By: James Ford

Overview of this book

Flash applications are popular and becoming increasingly social. With flash applications for facebook you can tap into a potential audience of half a billion existing users, their connections and affiliations, their uploaded images, posts, comments and more.The Flash Facebook Cookbook is packed with recipes for the Graph API and FQL, used for reading and writing data as well as interacting with Facebook anonymously or on behalf of an authorised Facebook User.The topics covered by the recipes in this Cookbook include working with News feeds, uploading Photos, searching for and plotting Places on a map and much more. The cookbook has recipes ranging from those that work without any authentication with Facebook to those that do, and act on behalf of a user. Packed with recipes that yield practical demonstrations of the Graph API functionality, the Flash Facebook Cookbook is an essential tool for Flash Platform developers.
Table of Contents (18 chapters)
Flash Facebook Cookbook
Credits
About the Author
Acknowledgement
About the Reviewers
www.PacktPub.com
Preface
10
Checkins and Facebook Places

Authentication with the Web SDK, for Flash Player applications


There are two main steps to the authentication process, when working with Facebook and its ActionScript 3 SDK:

  1. 1. The first step is to initialize the library, passing in a few application settings, such as the API Key, which will then be used to find any active Facebook sessions that our application can use.

  2. 2. The next step is manually logging in to Facebook and creating a new session, although this is optional, depending on whether or not the previous initialization was successful.

In this recipe, we're going to explore the simple tasks of initializing the Facebook ActionScript 3 SDK and logging in to Facebook, for a web-based Flash Player application.

Getting ready

Before we can start working with the Facebook APIs, we'll need the API Key for the application that we set up on the Facebook Developer Portal, in the recipe Setting up a new Application on Facebook from the previous chapter.

Create a new web project in Flash Builder...