<!--function WM_moveTo(daObject, endLeft, endTop, numSteps, delay, endFunction) {/*WM_moveTo()Moves an object from its current location to a new location and optionally fires a function when it's done.Source: Webmonkey Code Library(http://www.hotwired.com/webmonkey/javascript/code_library/)Author: Nadav SavioAuthor Email: nadav@wired.comUsage: WM_moveTo('objectName', endingLeft, endingTop, numberOfSteps, delayBetweenSteps, 'functionToFire()'); */  // Declare variables.  var leftInc, topInc, daObj = new Object;  // The first time through, create document.WM.WM_moveTo  if (typeof document.WM == 'undefined'){    document.WM = new Object;    document.WM.WM_moveTo = new Object;  } else if (typeof document.WM.WM_moveTo == 'undefined') {    document.WM.WM_moveTo = new Object;  }  // Store endFunction to execute when the move is finished.  if(endFunction) document.WM.WM_moveTo.endFunction = endFunction;  // Get a good object reference (call it daObj) from WM_checkIn().  // But if we've already done so, don't check it in again.    if (daObject == "sameObj") {      daObj = document.WM.WM_moveTo.daObj;    } else {      daObj = WM_checkIn(daObject);      document.WM.WM_moveTo.daObj = daObj;    }  // If this is the last step, go to the end point and run endFunction.  if (numSteps == 1) {    daObj.left = endLeft;    daObj.top = endTop;    // If an endFunction was set, execute it and then delete it.    if(document.WM.WM_moveTo.endFunction) {      daFunction = document.WM.WM_moveTo.endFunction;      document.WM.WM_moveTo.endFunction = '';      eval(daFunction);    }  } else {    // Otherwise, figure out how far to move.    leftInc = (endLeft - parseInt(daObj.left)) / numSteps;    topInc = (endTop - parseInt(daObj.top)) / numSteps;    // Then move, decrement numSteps, and do it all again.    daObj.left = parseInt(daObj.left) + leftInc;    daObj.top = parseInt(daObj.top) + topInc;    numSteps--;    setTimeout ('WM_moveTo(\'sameObj\', ' + endLeft + ', ' + endTop + ', ' + numSteps + ', ' + delay + ')', delay);  }}// -->
