views:

102

answers:

2

I'm looking to implement OpenSocial on my web application, which is written in php/mysql. What is the best way to go about doing this?

For instance, are there options along the way? Is one path better than another? What should my scope be for a good first version? I just want to get it working for version 1, is there a logical path to adding more and more of opensocial's features?

+1  A: 

There are many libraries out there, usually the particular OpenSocial provider (like MySpace) will have their own flavor. Here is a link to Myspace's, though I have not used it personally as we rolled out won custom library long ago.

The first thing to note is that no two OpenSocial providers are the same. Myspace is is different from Hi5, Friendster, Ning, etc. They all have little caveats to work around. Get used to this.

Now, the first problem you have to work around is that OpenSocial is client-side code that runs on a different domain from your server. This means that all the xhtml, javascript, etc must conform to the OpenSocial canvas. For IE6, this means operating in QuirksMode. Sucks, right? What we ended up deciding to do was to have OpenSocial load our site in an Iframe.

I wrote an introductory slide deck on this subject some time ago. The basic idea still applies today, though it may be a little out of date. You can download the slide deck here.

thesmart
+1  A: 

Your first stop shall be at google's OpenSocial PHP Client. There also exists a nice to read MySpace forum thread.

That's it.

tuergeist