drawing a binary tree with php gd from mysql data 
Author Message
 drawing a binary tree with php gd from mysql data

I am desparately trying to represent a binary tree using php and gd.
The hierarchy or genealogy data is stored in Mysql DB and can be
extracted to the format

a, b, c
b, d, e
c, f, g
d, h, i

and so on..
this I want to represent in an image say a png or gif

      O
     / \
    o   o
   /\   /\
  o  o o  o

in this way it should accomodate all the nodes and show the full tree.
certain nodes are having more than a 1000 nodes below that.



Fri, 12 Aug 2005 21:53:57 GMT  
 drawing a binary tree with php gd from mysql data

Quote:

> this I want to represent in an image say a png or gif

>       O
>      / \
>     o   o
>    /\   /\
>   o  o o  o

> in this way it should accomodate all the nodes and show the full tree.
> certain nodes are having more than a 1000 nodes below that.

Maybe you could use GraphViz instead to generate the image:

http://www.graphviz.org/

You would have to install it on the server.

James



Fri, 12 Aug 2005 22:18:59 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. drawing textual representations of binary trees

2. Inserting data from php form to MySQL

3. Using PHP to transfer data between 2 MySQL databases

4. Floats and LOAD DATA (PHP & MySQL)

5. formatting MySQL/PHP data into columns, rows, ecc.

6. PHP not inserting data correctly into MySQL

7. Binary trees storing huge amounts of data in nodes

8. php mysql sample code php shareware like KB knowledgebase

9. PHP+MySQL vs. PHP+PostgreSQL

10. php + mysql or php + postgresql?

11. Self-Adjusting Binary Search Trees (Splay Trees)

12. Self-Adjusting Binary Search Trees (Splay Trees)

 

 
Powered by phpBB® Forum Software