473,398 Members | 2,404 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

making forum tree

i have mysql table like this:

id | r_id | level | porder

where

id - post id
r_id - parent post id
level - post position in the tree (horizontal)
porder - post position in the tree (vertical)

i had to write a php script which paint tree like this:

level porder
p 0 0
|-p 1 1
|-p 1 2
| |-p 2 3
| |-p 2 4
| | |-p 3 5
| | |-p 3 6
| | \-p 3 7
| | \-p 4 8
| \-p 2 9
| |-p 3 10
| \-p 3 11
\-p 1 12

obwiously i replace asci charts equivalent gif's.
'|-', '| ', '\-', ' ' are separate gif's.
i'll be very grateful if somebody help my write this script.
Jul 17 '05 #1
0 1109

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Brian | last post by:
Greetings, I'm working on a project that involved that has need of a categorization system. Logically speaking, the system will have elements, these elements will belong to at least a single...
1
by: Paul | last post by:
Hi, I am looking for a BBS/Forum system which supports a threaded view of replies (i.e. like a tree view so you now who has replied to who at a glance). It can be a commercial product and...
19
by: Christian Fowler | last post by:
I have a VERY LARGE pile of geographic data that I am importing into a database (db of choice is postgres, though may hop to oracle if necessary). The data is strictly hierarchical - each node has...
3
by: Brian Henry | last post by:
How would you go about doing this I have a tree view which where anything is a parent it is a folder (folder icon, and the tag for the object is a string that says "FOLDER:{name of folder...
6
by: frizzle | last post by:
Hi there, I'm going to build a simple forum in mySQL. I've thought about it for a while now, but still can't figure it out completely: If i have say 5 main categories, One has 5...
1
by: muchexie | last post by:
My script is not running, can someone help me.This is the code. <? //display_tree() Function from output_funs.php function display_tree($expanded, $row = 0, $start = 0) { // display the tree...
10
by: Sebastian Bassi | last post by:
I have a two column list like: 2,131 6,335 7,6 8,9 10,131 131,99 5,10
31
by: DirtySnipe | last post by:
I have created a php form with dynamic drop down boxes in it which pull the options from a database. The boxes work fine and the data gets submitted fine but im having a problem getting the box to...
16
by: Andrea Gavana | last post by:
Hi Diez & All, Do you mind explaining "why" you find it *buttugly*? I am asking just out of curiosity, obviously. I am so biased towards wxPython that I won't make any comment on this thread...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.