<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
<!-- saved from url=(0084)http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html -->
<HTML><HEAD><TITLE>Folder tree with Drag and Drop capabilities</TITLE>
<META http-equiv=Content-Type content="text/html; charset=utf-8">
<META content="Alf Magne Kalleland (post@dhtmlgoodies.com)" name=Author>
<META content="MSHTML 6.00.2900.3354" name=GENERATOR>
<META
content="Folder tree with drag and drop,folder tree,list based folder tree,tree view,Drag and drop script,DHTML drag and drop,drag,drop"
name=KeyWords>
<META content="A library of DHTML and Ajax scripts" name=Description>
<META content=Norway name=country>
<META content=post@dhtmlgoodies.com name=organization-Email>
<META content="copyright 2005 - Alf Magne Kalleland" name=copyright>
<META content=Worldwide name=coverage>
<META content=30days name=revisit_after>
<META content="A library DHTML and Ajax scripts - DHTMLgoodies.com" name=title>
<META content=http://www.dhtmlgoodies.com/ name=identifier>
<META content=English name=language>
<META content=follow name=robots>
<META content="index, follow" name=googlebot>
<SCRIPT src="Folder tree with Drag and Drop capabilities.files/urchin.js"
type=text/javascript>
</SCRIPT>
<SCRIPT type=text/javascript>
// _uacct = "UA-85864-2";
_uacct = "UA-2042963-1";
urchinTracker();
</SCRIPT>
<SCRIPT src="Folder tree with Drag and Drop capabilities.files/ajax.js"
type=text/javascript></SCRIPT>
<SCRIPT src="Folder tree with Drag and Drop capabilities.files/context-menu.js"
type=text/javascript></SCRIPT>
<!-- IMPORTANT! INCLUDE THE context-menu.js FILE BEFORE drag-drop-folder-tree.js -->
<SCRIPT
src="Folder tree with Drag and Drop capabilities.files/drag-drop-folder-tree.js"
type=text/javascript>
/************************************************************************************************************
(C) www.dhtmlgoodies.com, July 2006
Update log:
This is a script from www.dhtmlgoodies.com. You will find this and a lot of other scripts at our website.
Terms of use:
You are free to use this script as long as the copyright message is kept intact.
For more detailed license information, see http://www.dhtmlgoodies.com/index.html?page=termsOfUse
Thank you!
www.dhtmlgoodies.com
Alf Magne Kalleland
************************************************************************************************************/
</SCRIPT>
<LINK
href="Folder tree with Drag and Drop capabilities.files/drag-drop-folder-tree.css"
type=text/css rel=stylesheet></LINK><LINK
href="Folder tree with Drag and Drop capabilities.files/context-menu.css"
type=text/css rel=stylesheet></LINK>
<STYLE type=text/css>IMG {
BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px
}
</STYLE>
<SCRIPT type=text/javascript>
//--------------------------------
// Save functions
//--------------------------------
var ajaxObjects = new Array();
// Use something like this if you want to save data by Ajax.
function saveMyTree()
{
saveString = treeObj.getNodeOrders();
var ajaxIndex = ajaxObjects.length;
ajaxObjects[ajaxIndex] = new sack();
var url = 'saveNodes.php?saveString=' + saveString;
ajaxObjects[ajaxIndex].requestFile = url; // Specifying which file to get
ajaxObjects[ajaxIndex].onCompletion = function() { saveComplete(ajaxIndex); } ; // Specify function that will be executed after file has been found
ajaxObjects[ajaxIndex].runAJAX(); // Execute AJAX function
}
function saveComplete(index)
{
alert(ajaxObjects[index].response);
}
// Call this function if you want to save it by a form.
function saveMyTree_byForm()
{
document.myForm.elements['saveString'].value = treeObj.getNodeOrders();
document.myForm.submit();
}
function test(){
/*var xml="<?xml version='1.0' encoding='utf-8'?><tree><item text='aaa' id='li0'><item text='bb' id='li0_0'></item><item text='cc' id='li0_1'><item text='c1' id='li0_1_0'><item text='c11' id='li0_1_0_0'></item></item></item></item></tree>";
*/
var xmlDoc =new ActiveXObject("Msxml2.DOMDocument");
xmlDoc.async=false;
//xmlDoc.loadXML(xml);
xmlDoc.load("d:\\tree.xml");
var node = xmlDoc.documentElement;
var ul = document.createElement("ul");
var result;
if (node != null){
createLIUL(node, ul);
}
document.all("tree").appendChild(ul);
//ul.class="dhtmlgoodies_tree";
ul.id="dhtmlgoodies_tree2";
}
function createLIUL(node, ul){
//li ul
for(var i = 0; i < node.childNodes.length; i++){
var text = node.childNodes.item(i).attributes.getNamedItem("text").nodeValue;
var id = node.childNodes.item(i).attributes.getNamedItem("id").nodeValue;
var li = document.createElement("li");
li.id = id;
ul.appendChild(li);
var an = document.createElement("a");
an.href = "#";
an.innerText = text;
li.appendChild(an);
if(node.childNodes.item(i).childNodes.length > 0){
var ulchild = document.createElement("ul");
li.appendChild(ulchild);
createLIUL(node.childNodes.item(i), ulchild);
}
}
}
//test();
</SCRIPT>
</HEAD>
<BODY>
<div id="tree">
<BR>
<UL class=dhtmlgoodies_tree id=dhtmlgoodies_tree2>
<LI id=node0 noRename="true" noDelete="true" noSiblings="true"
noDrag="true"><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Root
node</A>
<UL>
<LI id=node1><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Europe</A>
<UL>
<LI id=node2 noDelete="true"><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Norway</A>
<UL>
<LI id=node3 noRename="true"><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Stavanger</A>
<LI id=node6><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Bergen</A>
<LI id=node7><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Oslo</A>
</LI></UL>
<LI id=node8><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">United
Kingdom</A>
<UL>
<LI id=node9><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">London</A>
<LI id=node10><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Manchester</A>
</LI></UL>
<LI id=node12><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Sweden</A>
<LI id=node13><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Denmark</A>
<LI id=node14><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Germany</A>
<UL>
<LI id=node141><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Berlin</A>
<LI id=node142><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Munich</A>
<LI id=node143><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Stuttgart</A>
</LI></UL></LI></UL>
<LI id=node15><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Asia</A>
<UL>
<LI id=node151><A
href="http://www.dhtmlgoodies.com/scripts/drag-drop-folder-tree/drag-drop-folder-tree.html#">Japan</A>
<LI id=node152><A
href="http://www.dhtmlg
没有合适的资源?快使用搜索试试~ 我知道了~
js动态树合集(dtree,dhtmlxtree,drag-drop-tree)
共12个文件
js:5个
css:2个
zip:2个
5星 · 超过95%的资源 需积分: 10 243 下载量 97 浏览量
2008-08-07
15:29:52
上传
评论 2
收藏 533KB RAR 举报
温馨提示
dtree, dhtmlxtree(1.5普通版及1.3专业版), drag-drop-tree
资源推荐
资源详情
资源评论
收起资源包目录
js动态树合集.rar (12个子文件)
js动态树合集
Folder tree with Drag and Drop capabilities.htm 11KB
dhtmlxTree.zip 761KB
dtree.zip 15KB
dhtmlXTreeprofessional.rar 179KB
Folder tree with Drag and Drop capabilities.files
context-menu.js 11KB
drag-drop-folder-tree.css 1KB
context-menu.css 1KB
urchin.js 22KB
ajax.js 5KB
drag-drop-folder-tree.js 29KB
KonaLibInline.js 32KB
heading3.gif 4KB
共 12 条
- 1
资源评论
- yqfly20082013-07-29非常感谢分享,里面的例子很有用
- TINTIN20102011-11-04里面含dhtmlxtree的专业版,有动态的调用php的例子。很好用
- nicknameisnull2012-06-19试着改在jsp中用。还不错
simplyred4ever
- 粉丝: 1
- 资源: 21
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功