首先用js控制生成了一个组织结构图
再设置这个组织结构可以任意拖动到指定位置
页面代码如下 具体代码 实例 可以去我资源空间下载
复制代码 代码如下:
<!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>部门组织架构图</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link href="css.css" type="text/css" rel="stylesheet" />
<script src="jquery-1.8.3.min.js" type="text/javascript"></script>
<script src="jquery.ui.draggable.min.js" type="text/javascript"></script>
<script src="main.js" type="text/javascript"></script>
</head>
<body>
<div id="strtWrap">
<div>
<div>
<span>天云平台</span>
<div><span></span></div>
<div>
<div>
<span></span>
<div><span></span></div>
<span>档案类</span>
<div><span></span></div>
<div>
<div>
<span></span>
<div><span></span></div>
<span>档案</span>
</div>
<div>
<span></span>
<div><span></span></div>
<span>档案</span>
</div>
<div>
<span></span>
<div><span></span></div>
<span>档案</span>
</div>
<div>
<span></span>
<div><span></span></div>
<span>档案</span>
</div>
</div>
</div>
<div>
<span></span>
<div><span></span></div>
<span>搜索类</span>
<div><span></span></div>
<div>
<div>
<span></span>
<div><span></span></div>
<span>搜索</span>
</div>
<div>
<span></span>
<div><span></span></div>
<span>搜索</span>
</div>
<div>
<span></span>
<div><span></span></div>
<span>搜索</span>
</div>
<div>
<span></span>
<div><span></span></div>
<span>搜索</span>
</div>
</div>
</div>
<div>
<span></span>
<div><span></span></div>
<span>分析类</span>
<div><span></span></div>
<div>
<div>
<span></span>
<div><span></span></div>
<span>分析</span>
</div>
<div>
<span></span>
<div><span></span></div>
<span>分析</span>
</div>
<div>
<span></span>
<div><span></span></div>
<span>分析</span>
</div>
<div>
<span></span>
<div><span></span></div>
<span>分析</span>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>
【用js控制组织结构图可以任意拖拽到指定位置】相关文章:
★ 解决 FireFox 下[使用event很麻烦] 的问题.
★ JavaScript中用toString()方法返回时间为字符串
★ 表单提交验证类