Friday, August 6, 2010

Limitations and possible improvements

At the moment this solution is all I need, but this doesn't mean that it is complete. For instance, nested FBML is not possible via embed tags. A possible solution for this is using nestable HTML5 elements such as divisions (div).

Also, when inheriting the attributes from the embed element to the wrapper element I didn't check whether or not the attributes are valid in div's. Common attributes such as id, class and title will not cause any troubles, but for instance type will. The check could be done, but for me this is overhead since I'm aware of what attributes are valid when developing.

For the rest this solution should be quite flexible. Since I didn't hardcode any changes in the original connect script it keeps allowing updates from Facebook's JavaScript API.

I hope this can help other people who are embedding Facebook plug-ins in their websites. Any comments, remarks, improvements, ... are welcome.

Another thing I need to add is that I've only tested this code on Mozilla Firefox 3.6.x (FreeBSD 8.0 and Windows Vista) and IE8 (Windows Vista). Feel free to comment when your attempt has succeeded (or failed) on a specific browsers. Please include the browser's version and OS.

1 comment:

  1. Hi, great work with fbml5 it really saved my day, however, i think i found an error with the code, it seam like explorer 9 running compability mode on windows 7 is'nt working.

    ReplyDelete