Maybe I just need another pair of eyes or two, but it really seems as
if document.getEle mentById is choking on me. This page:
http://www.mortgageplans.com/mbc-net...ll.html?EC=245
has an input form field coded like so:
<input id="enrollCodeF ield" type="text" name="Code" value="" size="9"/>
And I've got the following javascript, which tries to get a reference
to that element and change its value:
x = document.getEle mentById('enrol lCodeField');
if(x) x.value = ec;
else alert('Can\'t find the input given id="enrollCodeF ield"');
(The whole script context can be found at
http://www.mortgageplans.com/javascript/refcode.js )
The above code always seems to trigger the alert, meaning....
document.getEle mentById('enrol lCodeField') apparently isn't retrieving
a reference to the input element id'd as enrollCodeField . I can't see
any apparent reason for this.
Oddly enough, if I call the Javascript Shell Bookmarklet
(http://www.squarefree.com/shell/ ) on that page, and type in
document.getEle mentById('enrol lCodeField'), it works as expected.
Any idea what I'm missing here?
Thanks,
Weston