The help house (www.bkjia.com) Tutorial helps a friend temporarily write "javascript implementation can be dragged layer example (layer drag, compatible with IE/FF)", it feels concise, the effect is also good, remember to avoid re-engineering the wheel next time.
 
 
<! DOCTYPE html PUBLIC "-// W3C // dtd xhtml 1.0 Transitional // EN "" http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd "> <Html xmlns =" http://www.w3.org/1999/xhtml "> <Head> <title> example of a layer where Javascript can be dragged-LIEHUO. NET) </title> <style type = "text/css"> # main div {position: absolute; width: 220px; height: 150px; border: 1px solid #999 ;} </style> 
Tip: the code can be modified before running!
This article was originally published in the blog Park, Author: Ding Xue, original address: http://www.cnblogs.com/dingxue/archive/2009/09/14/1566091.html