5D艺术网首页
商城
|
资讯
|
作品
|
博客
|
教程
|
论坛
登录
注册
加为好友
发短消息
来自:
性别:秘密
最后登录:2015-07-22
http://mb1978.5d.cn/
首页
|
新闻
|
话题
|
博客
|
相册
|
艺术作品
|
社交关系
|
留言板
|
社交圈
2006/07/28 | 树(多级目录)啊,不错!
类别(技术)
|
评论
(0)
|
阅读(157)
|
发表于 16:15
<style type="text/css">
<!--
td {
font-family: Arial, Helvetica, sans-serif;
font-size: 12px;
}
-->
</style>
<script language="javascript">
//<!--
//by jiakian - 2005.12.29
var ico_Root = "http://www.trade-ok.com/english/invest/images/index/topopen.gif";
var ico_Folder1 = "http://www.trade-ok.com/english/invest/images/index/foldericon.gif";
var ico_Folder2 = "http://www.trade-ok.com/english/invest/images/index/openfoldericon.gif";
var ico_File = "http://www.trade-ok.com/english/invest/images/index/htmlicon.gif";
var ico_I = "http://www.trade-ok.com/english/invest/images/index/I.gif";
var ico_L = "http://www.trade-ok.com/english/invest/images/index/L.gif";
var ico_L_Child1 = "http://www.trade-ok.com/english/invest/images/index/Lplus.gif";
var ico_L_Child2 = "http://www.trade-ok.com/english/invest/images/index/Lminus.gif";
var ico_T = "http://www.trade-ok.com/english/invest/images/index/T.gif";
var ico_T_Child1 = "http://www.trade-ok.com/english/invest/images/index/Tplus.gif";
var ico_T_Child2 = "http://www.trade-ok.com/english/invest/images/index/Tminus.gif";
var ico_O = "http://www.trade-ok.com/english/invest/images/index/white.gif";
var cengEnd = "";
function clickTree(e)
{
if(e.status == "close")
{
e.status = "open";
eval('document.all.span_' + e.id + ".style.display = 'block';");
clickID = e.id.replace("treeID","")*1;
eval("if(document.all.treeImg_A_" + clickID + ".mark == 'T')document.all.treeImg_A_" + clickID + ".src = ico_T_Child2");
eval("if(document.all.treeImg_A_" + clickID + ".mark == 'L')document.all.treeImg_A_" + clickID + ".src = ico_L_Child2");
eval("document.all.treeImg_B_" + clickID + ".src = ico_Folder2");
}
else if(e.status == "open")
{
e.status = "close";
eval('document.all.span_' + e.id + ".style.display = 'none';");
clickID = e.id.replace("treeID","")*1;
eval("if(document.all.treeImg_A_" + clickID + ".mark == 'T')document.all.treeImg_A_" + clickID + ".src = ico_T_Child1");
eval("if(document.all.treeImg_A_" + clickID + ".mark == 'L')document.all.treeImg_A_" + clickID + ".src = ico_L_Child1");
eval("document.all.treeImg_B_" + clickID + ".src = ico_Folder1");
}
}
function buquan(ID)
{
isTrue = false;
str = "";
try{
eval("if(document.all.treeImg_A_" + ID + ".mark == 'L')isTrue = true;");
if(isTrue)
{
str = str + eval("buquan(document.all.treeID" + ID + ".father);") + "</span>";
return str;
}
}
catch(e)
{
return "";
}
return "";
}
function initTree(ID,Father,Str,Level,Child,Next)
{
var str = '';
if(Child)
str = str + '<font style="cursor:hand" onClick="clickTree(this)" id="treeID' + ID + '" status="close" father="' + Father + '">';
else
str = str + '<font style="cursor:normal" id="treeID' + ID + '" status="file">';
for(j=1;j<Level;j++)
{
if(cengEnd.search(("#" + j)) == -1)
str = str + '<img align="absmiddle" src="' + ico_O + '">';
else
str = str + '<img align="absmiddle" src="' + ico_I + '">';
}
if(Next)
{
if(Child)
str = str + '<img align="absmiddle" src="' + ico_T_Child1 + '" id="treeImg_A_' + ID + '" mark="T">';
else
str = str + '<img align="absmiddle" src="' + ico_T + '" mark="T">';
if(cengEnd.search(("#" + Level)) == -1)cengEnd = cengEnd + "#" + Level;
}
else
{
if(Child)
str = str + '<img align="absmiddle" src="' + ico_L_Child1 + '" id="treeImg_A_' + ID + '" mark="L">';
else
str = str + '<img align="absmiddle" src="' + ico_L + '" mark="L">';
cengEnd = cengEnd.replace(("#" + Level), "");
}
if(Child)
str = str + '<img align="absmiddle" src="' + ico_Folder1 + '" id="treeImg_B_' + ID + '">';
else
str = str + '<img align="absmiddle" src="' + ico_File + '">';
str = str + ' ' + Str + "</font><br>";
if(Child)
str = str + '<span id="span_treeID' + ID + '" father="' + Father + '" status="close" style="display:none;">';
if(!Next && !Child)
{
str = str + '</span>';
str = str + buquan(Father);}
document.write(str);
}
//-->
</script>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td nowrap>
<script language="javascript">
document.write('<img align="absmiddle" src="' + ico_Root + '"> by jiakian - 2005.12.29<br><span>');
//ID,Father(属于哪个类),Str(文字),Level(级别),Child(是否有子类),Next(是否有下一个,是否为最后一个)
initTree(1,0,"<a href=tqkb.php?col=4>团青快报</a>",1,false,true);
initTree(2,0,"<a href=ztbd.php?col=6>专题报道</a>",1,true,true);
initTree(3,2,"<a href=ztbd.php?col=16>团委简报</a>",2,false,true);
initTree(4,2,"<a href=ztbd.php?col=17>团委通知</a>",2,false,true);
initTree(5,2,"<a href=ztbd.php?col=18>文化部团12大</a>",2,false,true);
initTree(6,2,"<a href=ztbd.php?col=19>增强团员意识教育</a>",2,false,false);
initTree(7,0,"<a href=hdpt.php?col=7>活动平台</a>",1,true,true);
initTree(8,7,"<a href=hdpt.php?col=20>读书活动</a>",2,false,true);
initTree(9,7,"<a href=hdpt.php?col=21>评选表彰</a>",2,false,true);
initTree(10,7,"<a href=hdpt.php?col=22>青年志愿者活动</a>",2,false,true);
initTree(11,7,"<a href=hdpt.php?col=23>思想教育工作</a>",2,false,true);
initTree(12,7,"<a href=hdpt.php?col=24>活动图片共享</a>",2,false,false);
initTree(13,0,"<a href=qlzj.php?col=8>青联之家</a>",1,true,true);
initTree(14,13,"<a href=qlzj.php?col=25>委员写真</a>",2,false,true);
initTree(15,13,"<a href=qlzj.php?col=26>委员动态</a>",2,false,true);
initTree(16,13,"<a href=qlzj.php?col=27>青联活动</a>",2,false,true);
initTree(17,13,"<a href=qlzj.php?col=28>演艺新星</a>",2,false,false);
initTree(18,0,"<a href=qqgh.php?col=9>亲切关怀</a>",1,true,true);
initTree(19,18,"<a href=qqgh.php?col=29>青年之友</a>",2,false,true);
initTree(20,18,"<a href=qqgh.php?col=30>讲话与文件</a>",2,false,true);
initTree(21,18,"<a href=qqgh.php?col=31>领导荐书</a>",2,false,false);
initTree(22,0,"<a href=wstx.php?col=10>网上团校</a>",1,true,true);
initTree(23,22,"<a href=wstx.php?col=32>团的知识</a>",2,false,true);
initTree(24,22,"<a href=wstx.php?col=33>党的知识</a>",2,false,true);
initTree(25,22,"<a href=wstx.php?col=34>入党积极分子园地</a>",2,false,false);
initTree(26,0,"<a href=zzjg.php?col=11>组织机构</a>",1,false,true);
initTree(27,26,"<a href=zzjg.php?col=35>关于我们</a>",2,false,true);
initTree(28,26,"<a href=zzjg.php?col=36>共青团文化部委员会</a>",2,false,true);
initTree(29,26,"<a href=zzjg.php?col=37>文化部青年联合会</a>",2,false,true);
initTree(30,26,"<a href=zzjg.php?col=38>文化部青年读书协会</a>",2,false,true);
initTree(31,26,"<a href=zzjg.php?col=39>文化部青年志愿者协会</a>",2,false,false);
initTree(32,0,"<a href=whsl.php?col=12>文化沙龙</a>",1,true,true);
initTree(33,32,"<a href=whsl.php?col=40>理论争鸣</a>",2,false,true);
initTree(34,32,"<a href=whsl.php?col=41>业务交流</a>",2,true,true);
initTree(35,34,"<a href=whsl.php?col=48>青年论坛</a>",3,false,true);
initTree(36,34,"<a href=whsl.php?col=49>岗位心语</a>",3,false,true);
initTree(37,34,"<a href=whsl.php?col=50>工作札记</a>",3,false,false);
initTree(38,32,"<a href=whsl.php?col=42>轻松生活</a>",2,true,true);
initTree(39,38,"<a href=whsl.php?col=51>人生走笔</a>",3,false,true);
initTree(40,38,"<a href=whsl.php?col=52>青春话语</a>",3,false,true);
initTree(41,38,"<a href=whsl.php?col=53>开心一刻</a>",3,false,false);
initTree(42,32,"<a href=whsl.php?col=43>热点话题</a>",2,false,true);
initTree(43,32,"<a href=whsl.php?col=44>评古论今</a>",2,false,true);
initTree(44,32,"<a href=whsl.php?col=45>文心诗穗</a>",2,false,true);
initTree(45,32,"<a href=whsl.php?col=46>美图共享</a>",2,false,true);
initTree(46,32,"<a href=whsl.php?col=47>英语角</a>",2,false,false);
</script>
</td>
</tr>
</table>
0
评论
Comments
日志分类
首页
[14]
综合
[2]
技术
[4]
杂谈
[8]