Embedded plugin objects
Web browser functionality is typically extended through browser plugins. Plugins are small desktop applications integrated with a web browser environment to provide additional on-page functionality. Adobe Flash, Microsoft Silverlight, and Apple QuickTime are three of the most popular browser plugin environments for widget creation. Each of these plugins create special forms of playback and interaction within a packaged application environment.
Browser plugin content executes these miniature external applications within a browser window, creating a small portlet into rendered content. Plugins extend a browser’s functionality by design, avoiding feature creep and licensing issues of a stand-alone browser. The ubiquity of popular plugins distributed through new PC sales, packaged with other applications, or installed on-demand help create a base ecosystem for development and code distribution. The capabilities of each plugin vary by version but, like modern browsers, most plugins ship with an automatic update mechanism.
Widgets powered by plugins function within a certain portion of the page defined by the
object elements. New content does not inherit the CSS styling on the page and therefore may stand-out in a blog sidebar or social network profile. Standing out could be a good, bad, or neutral thing depending on your content and the page owner’s design tastes.
Each target widget platform has a preferred method of handling plugin objects and occasionally restricted plugin access. I’ll outline a few popular platforms below.
MySpace widgets use Flash version 9 and above, requiring ActionScript 3, version 2 of the Adobe virtual machine interpreter, and converts HTML into its preferred
object format before saving content to a user’s profile.
Popular blogging software such as Movable Type and WordPress let authors install and configure specialized widgets designed for the platform and extended through plugins. Blog plugins are rendered as an integrated part of each blog page and exist as first-class citizens within a larger content structure.
A blog plugin might gather data on a regular basis on behalf of the blog author, storing a reference to his latest photographs stored on Slide or his latest bookmarks stored on del.icio.us in a local SQL database for quick and structured access. A blog author would configure the on-page display of gathered data through the blogging software’s built-in widget administration interface.
Blog plugins are executed on the server and delivered to a blog viewer’s browser as a single HTML file. Poorly written blog plugins could slow down or otherwise incapacitate an author’s blog so it’s especially important to follow best practices of integration and execution within this environment. Blog plugins are written for a specific version of a specific piece of blogging software. Database API and other software tie-ins change over time so you will need to choose a minimum version to support for best feature and addressable market trade-off.
Web widget content typically executes as a webpage within a webpage for security and containment purposes. The main web page loads all available widget content and creates appropriate inline sub-pages for each. These sub-pages are expressed within the page markup as inline frames (
iframe) or a HTML
object. Framed content isolates each web widget with limited privileges to protect page visitors from poorly written or malicious code.
Widgets within framed content do not have direct access to the full contents of the parent page or its user data. Web widget platforms serve as a bridge between the content and preferences of a main page and the framed widget content. A widget displaying photographs from your family vacation or the latest sports scores do not necessitate elevated privilege levels and perform well within a framed page environment. Widgets that request more permissions than needed could raise more author-facing warning messages within each widget platform. Widget developers should consider their on-page data requirements when creating and deploying a web widget.
Most web widget platforms allow developers to turn framed content on or off within a widget’s manifest file. Google Gadgets escape the frame if defined as
type “html-inline.” Netvibes references a
meta element named inline for a similar function. You should be able to adjust your widget’s permissions requirements before publishing to the outside world.
Some widget platforms offer widget certification and partner programs. Certified widgets might load from the same domain as the target platform — reducing warning messages and providing better run-time access — and usually carry a badge of honor and special promotion within a platform’s widget gallery.
Mix and mash