This is really difficult for me to wrap my head around, so please excuse me if I don't give a good enough explanation of the situation.
I have a table "tasks", and the only column that I'm really using for this problem is
| tasks_id |
| subtasks_id | subtasks_title | subtasks_tasks_id |
So I figured out what I had to do...
Using a multidimensional array, I can set the key to array
| tasks_id | of any existing subtasks, then the value of each will be a corresponding array where the
subtasks_tasks_id is the same as the key of the value. I then loop through each subtask by doing something like
$subtask[$tasks_id][$i] where I create two outer loops (one is already created, so it shouldn't be too difficult). And now I know what to do, next step is the how, or really the actual coding, okay, that is all..