Posts about using the JavaScript framework - Web 2.0 Javascript

11th May 2008 - 2 minutes read time is a JavaScript framework that allows you to add effects and advanced JavaScript features to any web page. Although can be a little slower than Mootools on occasion it makes up for this by having more stuff built into the library components. For example, the slider control is available of both frameworks, but the version comes with some handy features (like filling one part of the slider) where the Mootools version doesn't.

Read the full article Confine Draggable

2nd January 2008 - 4 minutes read time

Creating a new Draggable object with the framework is easy. You just create a new instance of the Draggable object with the element id to be made draggable as the first parameter and a set of options as the second.

<div id="dragMe"></div>
<script type="text/javascript">
new Draggable('dragMe',{revert:true});

The revert option will make the draggable element move back to the position it started from. More options can be added by separating them by commas, so to enable ghosting on the element as well as revert use the following.

new Draggable('dragMe',{revert:true,ghosting:true});

Ghosting means that when the element is dragged a ghost copy of the element moves with the mouse, where the original stays where it is until the mouse is released.

Read the full article