Mega Code Archive

 
Categories / JavaScript DHTML / Scriptaculous
 

Draggable with scroll bar

<html> <head> <title>Untitled Document</title> <script src="scriptaculous-js-1.8.2/lib/prototype.js" type="text/javascript"></script> <script src="scriptaculous-js-1.8.2/src/scriptaculous.js" type="text/javascript"></script> <script src="scriptaculous-js-1.8.2/src/unittest.js" type="text/javascript"></script> <script type="text/javascript"> Event.observe(window, 'load', function() {   new Draggable('my', { scroll: 'container' }); }); </script> </head> <body> <div id="container">   <p>A</p>   <p id="my">Drag this around!</p>   <p>C</p> </div> </body> </html>