fbml Archives - Page 2 of 2 - Stay N Alive

It’s Official, Facebook Releases Their Platform, Open Source and All

Nick O’Neill blogged about it, and Facebook confirmed it officially at the Palo Alto 1 Year Anniversary Developers Garage on Thursday, but Facebook has finally released their platform under a modified version of the Mozilla Public License. The code and announcement can be found here, and includes the full API, a parser for FBML, and more. I will probably be trying to sneak in a little info about this in FBML Essentials if I can beat it to press.

What does this mean for you? Well, first of all, there is a good chance (I have not confirmed this) you’ll now see sites like Myspace and LinkedIn also join sites like Bebo in providing a Facebook-style API. It should be an easy decision for them. This also means you are not stuck porting your Apps over to OpenSocial to get them on those networks, assuming they implement this into their own architecture. Ideally, it will take very few changes to port a Facebook App over to other FbPlatform-enabled sites.

Also, if you are building your own social network, you can now cater to all the Facebook developers out there and bring in the rich API Facebook provides. OpenSocial is great, but you do have to keep in mind it is still in beta – while new, I see no “beta” put in front of this new Facebook Open Platform.

The other thing you should take into account is that because it is Open Source, you can now contribute back to the platform. If you see something in the platform that is strongly needed, you simply have to sign the Contribution Agreement they provide and if they implement your change they’ll even send you a (drum roll please) T-Shirt! (they didn’t say if the T-Shirt was free or not) In reality though, we as developers now have some responsibility to give back to Facebook – that is the essence of Open Source.

I think Facebook just played their cards for Google on this one. Their environment is still closed, but at the very least they are sharing the components that make their closed environment so the world too can get involved. Google now has much stronger pressure to get OpenSocial in order, and in a way that convinces the Facebook platform developers to use OpenSocial instead of the Facebook Open Platform. It’s a race for developers, and I’m afraid Facebook just made the choice for developers to leap to OpenSocial a lot harder.

FBML Essentials Has a Cover!

fbml_essentials_comp.pngI received a copy of the cover for FBML Essentials last Friday. I was waiting to figure out what the bird was on the cover before I shared it. The bird is a White Throated Dipper – from Wikipedia:

The White-throated Dipper (Cinclus cinclus) is an aquatic passerine bird found in Europe and the Middle East, also known as the European Dipper or just Dipper. The species is divided into several subspecies on colour differences, especially of the pectoral band.

My Editor tells me that usually they don’t have reasons for the animals they have on the covers of O’Reilly books, and that they usually choose an animal that fits well with the look and feel of the book. I guess one could say that most birds are “Social” – anyone know anything more about the White-throated Dipper? Here’s a video of one in the wild:

You can pre-order the book here – it should be available in print around June or July, based on the production schedule they sent me. There’s always a chance it could be at Graphing Social Patterns in June. If not, look for it at OSCON in the O’Reilly booth (and who knows – maybe I’ll be there to sign your copy!).

UPDATE: I forgot to mention – Nick O’Neill of AllFacebook.com, and Rodney Rumford of FaceReviews.com did the Foreword and Afterword for the book. Thanks to both of them (Rodney wrote his Afterword on his birthday!) for putting the time in for those! It’s an excellent read and reference for all already into or looking to get into Facebook development!

Google Gets the Discussion Going on "Templates" for OpenSocial

This morning an e-mail went out to the OpenSocial and Gadget Spec Mailing List for OpenSocial developers, mentioning proposed problems and a need for “Templates” in OpenSocial. For those Facebook developers out there, this could be one of the missing links in OpenSocial, replacing the benefits of FBML for Facebook.

Read more about it on OpensocialNow!

Facebook Getting the Vote Out – but is it Good for Developers?

You’re seeing it here first folks – this morning Facebook announced a new tag on its wiki called . I imagine an announcement from Facebook will come soon on their purposes for this. From the wiki, :

Displays a Rock the Vote widget inline in your application. The text inside the tags is formatted as a hyperlink. When the user clicks the link, a Working Assets US Voter Registration dialog appears. When the user is done, they are prompted to share it with their friends. Then they are returned to your page.

This is particularly suitable for political apps or any app that wants to encourage voter registration.

Now, I’m not that familiar with the whole “Rock the Vote” organization, and I’m very for encouraging voter registration, but isn’t this also giving preferential treatment to other big organizations on Facebook? How did “Credo Mobile” get their sponsorship on this? Does this mean apps and organizations like my company’s client, “Takes All Types” will have their own tags for developers to use too? Has FBML been turned into an advertising tool? As a Facebook Developer myself I’m a little concerned about this one.

To implement the tag, you would do something like this (from the wiki):

Register to vote!

The link looks like this:

 link

And produces a form that looks like this:

rock the vote form, top

The second half of the form looks like this:

rock the vote form, bottom

Facebook Works to Reduce Spam Further With "Feed Forms"

Today, a new way of posting to the News Feed in Facebook appeared on the Facebook Developer’s wiki. Facebook introduced “Feed Forms”. To use a Feed form, you simply create a regular form as you would any other form, but add a special “fbtype” attribute to the form. The only documented value listed thus far is “publish”. Facebook then intercepts the form, reads the url in the action parameter, and prompts the user, asking them if they want to publish the story to their friends.

To use a “feed form”, the url in your action parameter for the form should return content in the form of JSON with a simple feed response. The example they give for return JSON data is this:

{ "method": { "fbtype" : "publish",

           "next": "http://my.canvas.com/next_page.php",

  "feed": {"title_template": "{actor} published status",

  "body_template" : "New status is \"{status}\"",

  "body_data" : {"status": $_POST['status']}}

}

I created a sample form that looks like this, returning the above data (changing the url) in application/x-json format:

Unfortunately it doesn’t seem this feature is live yet (or I’m just doing it wrong), as my returned JSON data just gets returned back to me when the form is submitted. I will post screen shots as soon as I hear confirmation that it has gone live (I expect that to be next Tuesday, when they usually do pushes).

Does this mean Facebook is doing away with the automated posting of News feeds by applications, or is it just one more way, and better way to make your feed story more likely to appear in your user’s friends’ news feeds? There is no official word from Facebook yet as to how they intend to use this.