Bob said the following on 10/21/2006 3:08 PM:
This works fine in IE6.
Probably because IE doesn't know the difference between a NAME attribute
and an ID attribute.
monDoc = document.getElementById('tbMonth');
mon = monDoc.value;
But Firefox doesn't recognize the value property. What works in FF?
Without seeing your HTML, that is impossible to answer.
You probably have an input with a name attribute of "tbMonth". If so,
use the form collection to access it:
document.forms['formIDnotName'].elements['elementNAMEnotID'].value;
Or, change your attribute from name to ID, or use both.
--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ -
http://jibbering.com/faq & newsgroup weekly
Javascript Best Practices -
http://www.JavascriptToolbox.com/bestpractices/