This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
There are two selects in a form called Form1, respectively called firstSelect and secondSelect. The firstSelect has an onchange event defined like this: <select name="firstSelect" onchange="changVal(this, document.myform.secondSelect)">
When the value changes, changVal(oElem,oTarget) is called. In changVal(), calling alert(oTarget.form.name) will display the form name Form1.
Can you please explain this ? I can't see anything about Select components having a property called form in the HTML Specification. Maybe I'm looking at the wrong spec.
(For those who own Ajax In Action, please refer to Listing 9.2, page 333)