<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>emu</title>
</head>
<body>
<script language="javascript">
function CHAPTER(t,p)
{
this.chapter=[];
this.title = t;
this.page=p;
}var book= new CHAPTER("JavaScript:The Definitive Guide",0)
book.chapter[0]=new CHAPTER("Introduction",3);     
book.chapter[1]=new CHAPTER("Lexical Structure",6);
book.chapter[0].chapter[0]=new CHAPTER("test1",3);
book.chapter[0].chapter[1]=new CHAPTER("test2",4);
book.chapter[1].chapter[0]=new CHAPTER("test3",6);
book.chapter[1].chapter[1]=new CHAPTER("test4",8);traverse(book)
function traverse(obj)
{
document.write(obj.title+"<br><BLOCKQUOTE>");
for (var i=0;i<obj.chapter.length;i++)
traverse(obj.chapter[i]);
document.write("</BLOCKQUOTE>");
}

</script>
</body>
</html>