Hi there,

you can do this with the snap-paramter. It 'normally' takes a value, but you 
can also pass it a function that sets the boundaries for your draggable 
element:

new Draggable('element', {
   snap: function(x, y) {
            return[ (x < 200) ? (x > 0 ? x : 0 ) : 200,
                    (y < 100) ? (y > 0 ? y : 0) : 100 ];
    }
});


The values 200 should be the width of your container MINUS the draggable's 
width and instead of 100 you should insert the container's height minus the 
height of the element.

Lukas

-- 
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en.

Reply via email to