| |||
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] |
In your example code, 'Day1' is a string and therefore does not have the .name property. If you are trying to access an element that has the name: 'dateDay1_year', then you can use eName (without .name). The document.getElementById() will find the correct element.
On Wednesday, November 01, 2006, at 02:23AM, "Malcolm Fitzgerald" <email@hidden> wrote:
On 01/11/2006, at 12:14 PM, Marcelo Alves wrote:Try :
function displayDate(eName) { var yy = 'date' + eName.name + "_year"; var yyIndex = document.getElementById(yy).selectedIndex; }
When I call displayDate('Day1') eName is 'Day1' and eName.name is undefined. yy ends up being "dateUndefined_year"
_______________________________________________ Do not post admin requests to the list. They will be ignored. Web-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/web-dev/email@hidden
| Home | Archives | FAQ | Terms/Conditions | Contact | RSS | Lists | About |
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE
Contact Apple | Terms of Use | Privacy Policy
Copyright © 2007 Apple Inc. All rights reserved.