You can access object properties in a natural fashion such as: |
var actualselected = worldmenu.menuselection; |
familymenu.color = 'red'; |
Curiously you can also use in Netscape 2 an array like notation to which we will return: |
familymenu[0] is same as familymenu.no |
familymenu[1] is same as familymenu.name etc. |
We will return to this when we discuss arrays |
One can associate methods with user objects but with a syntax that appears very limiting as object methods have identical arguments to function |
General Syntax is: |
Objectname.methodname = functionname; |
where Objectname is an existing Object and functionname is an existing function -- it can be used to set event handlers with no arguments! |