我有几个文字做到层里了,怎么能限制这个层的拖动范围,并取到这个层随意在这个限制区域拖动的坐标?
<div   style='position:absolute;width:200;height:200;'   onmousedown=MouseDown(this)   onmousemove=MouseMove()   onmouseup=MouseUp()><fon t color=red>可以拖动我</font></div>   
  <script>   
  var   Obj   
  function   MouseDown(obj){   
  Obj=obj   
  Obj.setCapture()   
  Obj.l=event.x-Obj.style.pixelLeft   
  Obj.t=event.y-Obj.style.pixelTop   
  }   
  function   MouseMove(){   
  if(Obj!=null){  
 
}
 }
</script>