Tree walking
Pressing the above buttons will:
- launch the do_document function with 2 arguments: A name of a CSS class and a color
- The do_document function will extract the body and then call the mark_tags function with arguments body, css_class and color
- The mark_tags function will examine all children of body and if there are are, also the children of these children, etc.
- Each time we find an element node that has an attribute class="important", we will change its style to a given color
Let's hope you enjoy this
If you want to reuse this code:
Made by Daniel K. Schneider, TECFA. This is freeware.
Last modified: Wed Apr 18 10:38:59 W. Europe Standard Time 2007