+++ /dev/null
-<!DOCTYPE html>
-<html lang="de-DE" class="no-js">
-<head>
- <title>Mif Tree with latest Mootools</title>
- <script type="text/javascript" src="mootools-core-1.3.2-full-nocompat.js"></script>
- <script type="text/javascript" src="mootools-more-1.3.2.1.js"></script>
- <script type="text/javascript" src="mif.tree-v1.2.6.4.js"></script>
-</head>
-<body>
- <script type="text/javascript">
- window.addEvent('domready',function(){
- tree = new Mif.Tree({
- container: $('tree_container'),// tree container
- types: {// node types
- folder:{
- openIcon: 'mif-tree-open-icon',//css class open icon
- closeIcon: 'mif-tree-close-icon'// css class close icon
- }
- },
- dfltType:'folder',//default node type
- height: 18//node height
- });
-
- var json = [
- {
- "property": {
- "name": "root"
- },
- "children": [
- {
- "property": {
- "name": "node1"
- }
- },
- {
- "property": {
- "name": "node2"
- },
- "state": {
- "open": true
- },
- "children":[
- {
- "property": {
- "name": "node2.1"
- }
- },
- {
- "property": {
- "name": "node2.2"
- }
- }
- ]
- },
- {
- "property": {
- "name": "node4"
- }
- },
- {
- "property": {
- "name": "node3"
- }
- }
- ]
- }
- ];
-
- // load tree from json.
- tree.load({
- json: json
- });
-
- });
- </script>
-
- <h1>Simple Tree example</h1>
- <div id="tree_container"></div>
-
-</body>
-</html>
\ No newline at end of file