惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

F
Fortinet All Blogs
Attack and Defense Labs
Attack and Defense Labs
V2EX - 技术
V2EX - 技术
O
OpenAI News
S
Secure Thoughts
H
Heimdal Security Blog
Application and Cybersecurity Blog
Application and Cybersecurity Blog
Schneier on Security
Schneier on Security
H
Hacker News: Front Page
S
Security Affairs
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
Vercel News
Vercel News
Microsoft Security Blog
Microsoft Security Blog
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
P
Proofpoint News Feed
The Register - Security
The Register - Security
GbyAI
GbyAI
Cloudbric
Cloudbric
MongoDB | Blog
MongoDB | Blog
D
Darknet – Hacking Tools, Hacker News & Cyber Security
K
Kaspersky official blog
Forbes - Security
Forbes - Security
Y
Y Combinator Blog
C
CXSECURITY Database RSS Feed - CXSecurity.com
Scott Helme
Scott Helme
Hacker News - Newest:
Hacker News - Newest: "LLM"
The Cloudflare Blog
Recorded Future
Recorded Future
人人都是产品经理
人人都是产品经理
Cyberwarzone
Cyberwarzone
C
CERT Recently Published Vulnerability Notes
Webroot Blog
Webroot Blog
C
Cyber Attacks, Cyber Crime and Cyber Security
L
LangChain Blog
T
Tor Project blog
Microsoft Azure Blog
Microsoft Azure Blog
博客园_首页
Hacker News: Ask HN
Hacker News: Ask HN
Blog — PlanetScale
Blog — PlanetScale
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
B
Blog RSS Feed
N
News and Events Feed by Topic
阮一峰的网络日志
阮一峰的网络日志
I
Intezer
V
V2EX
T
Tailwind CSS Blog
SecWiki News
SecWiki News
NISL@THU
NISL@THU
C
Check Point Blog

博客园 - Stym--闫生

最简单的silverlight的DataGrid行双击事件添加 == 在cmd命令下imp oracle dmp文件 flex TabNavigator 切换之前给出提示 - Stym--闫生 vb.net连接oracle和php连接oracle - Stym--闫生 - 博客园 数据库名,全局数据库名,SID 创建同义词和赋权限 linux下创建硬连接 flex 的as文件引用,包引用 - Stym--闫生 - 博客园 flex分页控件 - Stym--闫生 - 博客园 数据处理:等待条 把数组转化成一个xml字符串--php - Stym--闫生 - 博客园 php使用ajax技术 flex + Amfphp + mysql +IIS 5.1t 用sql查看表结构 c#生成验证图片 C#使用sql语句读取excel文件数据 svn切换用户,报“501 Method Not Implemented”错误 div滤镜结合ajax,实现登录
javascript拖住布局demo
Stym--闫生 · 2008-11-03 · via 博客园 - Stym--闫生

<script type="text/javascript">

   /*分析:整个过程分三步走,分别是:获取对象,移动对象,释放对象

     这三个步骤用鼠标的事件来对应是:onmousedown,onmousemove,onmouseup

   */
    var x,y,z,down=false,obj;
    function init(){
        obj=event.srcElement;       //获取焦点对象
        obj.setCapture();              //设置鼠标捕捉
        z=obj.style.zIndex;           //取得原z轴位置
        obj.style.zIndex=100;       //设定在最上层
        x=event.offsetX;              //获取鼠标指针相对于触发事件的对象的x位置
        y=event.offsetY;              //获取鼠标指针相对于触发事件的对象的y位置
        down=true;                     //设置鼠标状态为按下状态
    }
    function move(){
        if(down&&event.srcElement==obj){
            with(obj.style){
                posLeft=document.body.scrollLeft+event.x-x;
                posTop=document.body.scrollTop+event.y-y;
            }
        }
    }
    function up(){
        down=false;
        obj.style.zIndex=z;
        obj.releaseCapture();
    }
  </script>
</head>
 
<div id="1" onmousedown="init()" onmousemove="move()" onmouseup="up()" style="position:absolute;top:100px;left:100px;
width:100px;height:150px;border:1px solid #ccc;background:red;z-index:1">div1</div>
<div id="2" onmousedown="init()" onmousemove="move()" onmouseup="up()" style="position: absolute;top:150px;left:150px;
width:100px;height:150px;border:1px solid #666;background:blue;z-index:2">div2</div>
<div id="3" onmousedown="init()" onmousemove="move()" onmouseup="up()" style="position: absolute;top:200px;left:200px;
width:100px;height:150px;border:1px solid #999;background:green;z-index:3;">div3</div>