Hey everyone!
Wow Web2py 2.0 looks so cool! I can't wait to try all the new features.
This has made it so easy for me (a non-programmer) to make viable web
applications!
My question is as follows:
For one of my views, each page in my application has a variable number of
"child pages", each of which can have a variable number of "child pages",
and so on. I want each child page to have its own div like so:
<div> <---- the big container div
<div> <---- variable number of divs here
<div></div> <---- variable number of child div's here
each with their own text
</div>
<div>
How do I write the controllers, so that it recurses as deep as the deepest
node and generates those divs??
My design is as follows:
Two tables:
table1
-id (auto generated)
-field for text
table2
-id(autogenerated)
-parent_id(created from form)
-childid(created from form)
I know that I have to write a function that returns a div for each, but I
just wasnt sure how to do it.
Please help!
Thanks!
--