The plugins site is currently in development.
We've been looking to provide a higher-quality, spam-free experience at the plugins site for some time, and a major error on our part forced us to shut down the current site before we could put the new one in place. We are developing a new site, and you can follow along with its development on GitHub. For more information about this transition, including steps you can take as a plugin author to prepare, please read our post about what's going on.
jMover plugin
jMover (a jQuery list item mover) v1.2
What is jMover? It is a jQuery plugin to move all or selected options between two select boxes
Settings
Available settings and their defaults
/**
* Plugin defaults.
*
* @access public
*/
$.fn.jmover.defaults = {
/**
* The ID of the source field container.
* Needed for auto creation
*
* @var string
*/
toID: 'to',
/**
* The label of the source field container.
* Needed for auto creation
*
* @var string
*/
toLabel: 'Target',
/**
* The ID of the target field container.
* Needed for auto creation
*
* @var string
*/
fromID: 'from',
/**
* The label of the target field container.
* Needed for auto creation
*
* @var string
*/
fromLabel: 'Source',
/**
* The ID of the source select field
*
* @var string
*/
sourceID: 'exampleSource',
/**
* The ID of the target select field
*
* @var string
*/
targetID: 'exampleTarget',
/**
* Size of the select fields
*
* @var integer
*/
size: 15,
/**
* Auto create the mover elements
* 1 - Yes
* 0 - No
*
* @var integer
*/
create: 1,
/**
* The action we want to do.
*
* @var string
*/
action: null
};Example Init code to initialize static list boxes
(function() {
$("#example").jmover({
action: 'init',
create: 0,
sourceID: 'not_selected',
targetID: 'selected'
});
});
Dynamic list boxes
(function() {
$("#example").jmover({
action: 'init',
create: 0,
sourceID: 'not_selected',
targetID: 'selected'
});
});One could create list boxes on the fly and populate them later with AJAX or another function
Example init code
(function() {
$("#container").jmover({
action: 'init'
});
});Downloads
Resources
Development
(1 vote)
