| CARVIEW |
Sortable
Behaviours > Sortable
A Sortable is a quick way to initialize many Draggable elements in a container element. When you create a new Sortable, it takes care of the creation of the corresponding draggable Droppables.
Syntax
Use Sortable.create('id_of_container',[options]); to create new Sortables. See Sortable.create. Furthermore, there are special requirements to get sortables to work in FF3 which are also covered in Sortable.create.
Object
| Property/Method | Description |
|---|---|
| SERIALIZE_RULE | |
| sortables | (Object) { } |
| options (element) | Internal function |
| destroy (element) | Destroys sortable |
| create (element, options) | Creates sortable |
| findElements (element, options) | Internal function |
| onHover (element, dropon, overlap) | Internal function, which may be overridden through the options parameter on creation |
| onEmptyHover (element, dropon, overlap) | Internal function |
| unmark() | Internal function |
| mark() | Internal function |
| tree (element) | |
| sequence (element) | |
| setSequence (element, new_sequence) | |
| serialize (element) |
Demos
See Sortable Lists Demo.
Creating sortables
See Sortable.create.
Disabling sortables
Sortable.destroy( element );
A call to Sortable.create implicitly calls Sortable.destroy if the referenced element was already a Sortable.
Functions
| Function | Description |
| Sortable.serialize | The Sortable object also provides a function to serialize the Sortable in a format suitable for HTTP GET or POST requests. This can be used to submit the order of the Sortable via an Ajax call. See Sortable.serialize |
| Sortable.sequence | The Sortable object also provides a function to get the values in an sequence array object. See Sortable.sequence |
Tutorials
Use PHP and Ajax call to interact with Sortable
A short tutorial on using Sortables prepared for the Linux Users Group, Villafranca, Italy.
Pages
- Ajax.Autocompleter
- Ajax.InPlaceCollectionEditor
- Ajax.InPlaceEditor
- Autocompleter.Base
- Autocompleter.Local
- Behaviours Overview
- Builder
- Combination Effects
- Combination Effects Demo
- Contribute
- Controls Overview
- Core Effects Overview
- Demos
- Draggable
- Draggables Object
- Droppables
- Effect.Appear
- Effect.BlindDown
- Effect.BlindUp
- Effect.DropOut
- Effect.Fade
- Effect.Fold
- Effect.Grow
- Effect.Highlight
- Effect.Methods
- Effect.Morph
- Effect.Move
- Effect.multiple
- Effect.Opacity
- Effect.Parallel
- Effect.Puff
- Effect.Pulsate
- Effect Queues
- Effect.Scale
- Effect.ScrollTo
- Effect.Shake
- Effect.Shrink
- Effect.SlideDown
- Effect.SlideUp
- Effect.Squish
- Effect.SwitchOff
- Effect.tagifyText
- Effect.toggle
- Effect.Transitions
- Effect.Tween
- Effects Overview
- FAQ
- Form.Element.DelayedObserver
- In Place Editing
- License
- List Morph Demo
- Puzzle Demo
- Ruby on Rails
- Slider
- Sortable
- Sortable.create
- Sortable Lists Demo
- Sortable.sequence
- Sortable.serialize
- Sortables
- Sortables.create
- Sound
- Style Guide
- Tabs
- Test.Unit
- Test.Unit.Assertions
- Test.Unit.Logger
- Test.Unit.Runner
- Test.Unit.Testcase
- Unit Testing

JavaScript documentation, JavaScript API
script.aculo.us was created by Thomas Fuchs, and is extended and improved by open-source contributors. script.aculo.us is released under the MIT license.