[jstree] bind select_node.jstree 事件不起作用

16 views
Skip to first unread message

Julian Wong

unread,
Jan 16, 2011, 9:26:22 PM1/16/11
to ralasa...@googlegroups.com
/ralasafe/WebContent/ralasafe/query/designWhere.jsp
该文件装载树后,我想使用bind来监听onclick事件,没有效果。

<script type="text/javascript">
jQuery("#where").bind("select_node.jstree", function (event, data) {
alert("TREE IS selected");
}).jstree({ 
"xml_data" : {
"ajax" : {
"url" : "../query/designQuery?oper=loadWhere&queryId=<%=queryId%>"
},
"xsl" : "nest"
},
"plugins" : [ "themes", "xml_data" ]
});
</script>

树能够正常加载,点击任何节点不弹出消息。



--
Julian Wong    汪金保  
@ralasafe (twitter, 新浪)
http://www.ralasafe.org ( Open Source Access Control Middleware )

chen david

unread,
Jan 17, 2011, 3:02:02 AM1/17/11
to ralasa...@googlegroups.com
不是太清楚,好像应该是类似 bind('click',function(event){});
bind(eventType,data,listener);

Reply all
Reply to author
Forward
0 new messages