-------------------------------------------------------------------------
READ ME (readme.txt)
-------------------------------------------------------------------------
This is a short read me file for a NodeTree components and a sample
node modifying tool.
NodeTree.php is a class that works in conjuctions with Node and PhpDtObject
classes to easily create and modify hierarchical trees for categorizing
purposes. Trees are constructed with materialized paths on two dimensional
tables in mysql database. Basic methods (actions) includes adding, editing
and deleting nodes as well as copying, moving and ordering nodes.
Package includes index.php file, that is a script to make modifying trees
possible straight from the web interface. Script prints standard html list
and with stylesheet and javascript files makes hierarchical data visually
accessable. Query debug information is dumped at the end of the script.
Structuring data in a hierarchal way is a basic operation when creating more
advanced information handling applications. When extending NodeTree with own
methods it is possible to retrieve xml like structured data from database in many
handy ways.
---
Index.php requires config.php and actions.php files to work properly.
Additionally you need some media files (style.css, script.js and .gif files)
for web interface.
NodeTree works with next database table schema:
CREATE TABLE `treetest` (
`node_id` int(11) NOT NULL auto_increment,
`node_path` varchar(255) NOT NULL default '',
`node_depth` int(11) NOT NULL default '0',
`node_order` int(11) NOT NULL default '0',
`node_title` varchar(255) NOT NULL default '',
`node_has_childs` tinyint(4) NOT NULL default '0',
PRIMARY KEY (`node_id`),
KEY `node_id` (`node_id`),
KEY `node_path` (`node_path`),
KEY `node_depth` (`node_depth`),
KEY `node_order` (`node_order`),
KEY `node_title` (`node_title`),
KEY `node_has_childs` (`node_has_childs`)
) TYPE=MyISAM;
INSERT INTO `treetest` VALUES
('1','x','1','0','1','1'),
('2','x','1','1','2','0'),
('3','x','1','2','3','1'),
('4','x.3','2','1','3.1','0'),
('5','x.3','2','2','3.2','0'),
('6','x.3','2','3','3.3','0'),
('7','x.1','2','0','1.1','0');
Please see files and comments inside them to get more info how they work.
JavaScripts and stylesheets are tested succesfully on
- mac safari 2.0.3, firefox 1.5.0.1, netscape 7.2 and omniweb 5.1.1
- pc firefox 1.0.1
Php scripts and classes are tested succesfully on:
- Apache 1.3.33, PHP 5.0.4, MySql 4.1.3
- Apache 1.3.34, PHP 4.4.2, MySql 4.1.14
Opera and Internet explorer seems to have problems with javascript and
styles at this moment.
**************************************************************************
Marko Manninen <marko@multimediastudio.fi>
Copyright (c) 2006, Multimediastudio
LGPL - Lesser General Public License
v. 1.0 2006/21/03 <marko@multimediastudio.fi>
|