According to the developer documentation jquery plugins are supposed to have only one namespace for all functions they make available. Which is straight forward as long as you only expose a single function per context (static/element).
(function($){
var
state_a = 0,
$.myplugin = function(in_options) {
// static
return this;
}
$.fn.myplugin = function(in_options) {
// element
return this;
}
})(jQuery);
This makes calls like this possible:
$("elem").myplugin(options);
jQuery.myplugin(options);
What's the best approach if you have more than one function and need to share state? I would like to call into my plugin like this:
$("elem").myplugin.start(options);
$("elem").myplugin.stop();
jQuery.myplugin.start(options);
jQuery.myplugin.stop();
With IBM DB2 9.7's new compatibility and enablement features, DBAs tasked with moving Oracle databases to DB2 will find out-of-the-box "enablement" functionality that streamlines tasks and fast tracks time to completion.
<b>Inatux:</b> "Games have become the topic of late. Osmos developers wonder whether there is enough market share for GNU+Linux game ports to be worth the cost, but they aren't the only ones. It's been discussed time and time again, is a GNU+Linux -- or really any Unix or Unix-like -- port worth it?"
Developers behind the open source WebKit browser engine and Mozilla Firefox are seeking to take plugins out of the regular browser process to help make the browser more stable. Will it work?
<b>OSNews:</b> "Software patents, however, are only valid in some parts of the world, so an enterprising developer has started a project that was sure to come eventually: Firefox builds with H264 support."
<b>PACKT Publishing: </b>"With Amazon SimpleDB you can scale your application's database on the cloud. We are going to sign up for an AWS account, download and install the necessary libraries, and create little code snippets for exploring SimpleDB."
<b>Tux Radar:</b> "And with Linux and free software making a name for itself in the world of big business, many more people are testing the feasibility of switching small and home office software to their open source equivalents."
What if you could directly read and manipulate data at the block level? Oracle provides such a tool to do exactly that, but you have to build it yourself. The Block Browser and Editor tool, or bbed for short, is your ticket into the contents of data blocks within an Oracle database.
<b>Daniweb:</b> "No one has given his life for Linux but certainly there have been sacrifices. But, like their armed soldier counterparts, it isn't about the sacrifice, it's the freedom you big dummy."
<b>OSOR.EU:</b> "Public administrations that consider using open source software may need advise on how and why public agencies can acquire such software."