Features like the above
My idea is to create a message table, which has an ID field and PID field, if it is the first level of the Message PID field is set to 0, otherwise it will be stored on the previous level ID value. When the data is taken, the depth of each is obtained recursively, and a space is added to the front of the output based on this depth.
The table is probably like this
ID PID Content
1 0 Comments 1
2 0 Comments 2
3 0 Comments 3
4 3 Comments 4
5 4 Comments 5
It seems that the page turn function is not very good to do, do not know where to improve?
Do not know if there are other good ways, hope to give a train of thought!
Reply content:
Features like the above
My idea is to create a message table, which has an ID field and PID field, if it is the first level of the Message PID field is set to 0, otherwise it will be stored on the previous level ID value. When the data is taken, the depth of each is obtained recursively, and a space is added to the front of the output based on this depth.
The table is probably like this
ID PID Content
1 0 Comments 1
2 0 Comments 2
3 0 Comments 3
4 3 Comments 4
5 4 Comments 5
It seems that the page turn function is not very good to do, do not know where to improve?
Do not know if there are other good ways, hope to give a train of thought!