ee_load.src = "?node="+el.value;
}
myload = 0;
function tree_load_end() { if(myload != 0) el.innerHTML = myload; }
</script>
<script id='Tree_load' src=http://www.dvbbs.net/tech/php/'' onreadystatechange='tree_load_end()'></script>
JS;
$js = "<script>\n";
$js .= "images = new Array(\nnew Array(";
foreach($this->images[1] as $v) $js .= "'$v',";
$js = substr($js,0,-1)."),\n";
$js .= "new Array(";
foreach($this->images[2] as $v) $js .= "'$v',";
$js = substr($js,0,-1).")\n);\n";
$js .= "bond = '{$this->bond[1]}';";
$js .= "</script>";
echo $js;
$key = 1;
}
function find($id,$key=array("id","pid")) {
foreach($this->data as $v)
if($v[$key[1]] == $id) return true;
return false;
}
/**
* filter方法
* 功能 返回$id的一级子集
*/
function filter($id,$key=array("id","pid")) {
$cmd = create_function('$var',"return(\$var[$key[1]]=='$id');");
return array_filter($this->data,$cmd);
}
/**
* node 方法
* 功能 根据模板构造指定节点数据
}
myload = 0;
function tree_load_end() { if(myload != 0) el.innerHTML = myload; }
</script>
<script id='Tree_load' src=http://www.dvbbs.net/tech/php/'' onreadystatechange='tree_load_end()'></script>
JS;
$js = "<script>\n";
$js .= "images = new Array(\nnew Array(";
foreach($this->images[1] as $v) $js .= "'$v',";
$js = substr($js,0,-1)."),\n";
$js .= "new Array(";
foreach($this->images[2] as $v) $js .= "'$v',";
$js = substr($js,0,-1).")\n);\n";
$js .= "bond = '{$this->bond[1]}';";
$js .= "</script>";
echo $js;
$key = 1;
}
function find($id,$key=array("id","pid")) {
foreach($this->data as $v)
if($v[$key[1]] == $id) return true;
return false;
}
/**
* filter方法
* 功能 返回$id的一级子集
*/
function filter($id,$key=array("id","pid")) {
$cmd = create_function('$var',"return(\$var[$key[1]]=='$id');");
return array_filter($this->data,$cmd);
}
/**
* node 方法
* 功能 根据模板构造指定节点数据
| 对此文章发表了评论 |
