special immediate form: TREE special immediate form: TREE special immediate form: TREE

Often browser displays information from database.
Typical operation is viewing of some TREE:
smaller part of tree is shown in browser,
bigger part was not still inquired from database.

Let's enter a special form (looks like tree),
which would immediately send request to server,
if user opens folder (and wants to see sub-folders).
 It would be very comfortable and economize time and torment
 (especially for un-experienced user).

<tree name="A" action="script.cgi">

tree {
  src: root.gif
}
ti {
  src: folder.gif
}

When browser meet this html-element during loading document,
it immediately sends "name=A&id=null",
gets and displayes all folders of top level.
After that, tree looks like so (code below is not really inside document!)

<tree action="script.cgi">
  <ti id=1> folder_name1 </ti>
  <ti id=2> folder_name2 </ti>
  <ti id=5> folder_name5 </ti>
</tree>

If user opens folder with "id=2", then browser immediately sends "name=A&id=2".
After that, trees looks like so

<tree action="script.cgi">
  <ti id=1> folder_name1 </ti>
  <ti id=2> folder_name2
    <ti id=3> folder_name3 </ti>
    <ti id=4> <any_html_element> </ti>
  </ti>
  <ti id=5> folder_name5 </ti>
  </ti>
</tree>

Server answers to browser by piece of html-text with
TI-elements and any other html-elements, enclosed into TI.
For example above:

<ti id=2>
  <ti id=3> folder_name3 </ti>
  <ti id=4> <any_html_element> </ti>
</ti>

Received on Friday, 13 April 2007 12:27:56 UTC