function PrintTagsInDOM(startBox, reverse)
{
if (startBox)
{
var box = startBox;
while (box)
{
shell.print("Tag: " + box.tag);
if (reverse)
box = box.previousBox;
else
box = box.nextBox;
}
}
}