- Apr 5, 2002
- 24,326
- 68
- 91
Did you try the BMR calculator? I am also using Firefox 1.0pr and it doesnt work, nor does it work on older versions of Firebird.Originally posted by: Shagga
It works fine, well the page looks fine should I say on my installation of Firefox 1.0PR
Originally posted by: MrChad
Use the full DOM path when updating your input value:
document.frmMyForm.output.value = ...
replace "frmMyForm" with whatever you named your form.
Originally posted by: edro13
Did you try the BMR calculator? I am also using Firefox 1.0pr and it doesnt work, nor does it work on older versions of Firebird.Originally posted by: Shagga
It works fine, well the page looks fine should I say on my installation of Firefox 1.0PR
Originally posted by: 1Cheap2Crazy
Nice article. I can't help you with your problem, but I noticed some typos. I hope you don't mind.
1. Last sentence before Fig. 2 "He is...". I think you mean't "Here".
2. 2 paragraph after Fig 2, "Feel free yo click...". I think you mean't "to".
3. The BMR box thing has "Height is Inches", "in", and Estimated was misspelled.
And maybe it's just me, but I had a hard time understanding the first part of this sentence, "To know how many calories a day you need to lose weight, use a simple BMR calculator."
The calculator doesn't work for me. I'm using FF 1.0PR.
HTH,
1c2c
Originally posted by: edro13
Hmmm... I just tried it with that code, and it still works in IE, but not in Firefox.
You think it could have something to do with: onKeyUp="bmr();" ?
Lemme fire it off using a button instead.
Originally posted by: 1Cheap2Crazy
Not working in Firefox, but it's working in IE. BTW, "Esitmated" should be "Estimated".
Originally posted by: stndn
Look closely at these two code snippets from your page:
<script language="javascript" type="text/javascript">
var output = document.getElementById('output');
var inputInch = document.getElementById('inputInch');
var inputPound = document.getElementById('inputPound');
var inputAge = document.getElementById('inputAge');
</script>
and
<input name="inputInch" id="inputInch3" size="0" maxlength="4" type="text" width="50">
<input name="inputPound" id="inputPound4" maxlength="4" type="text" width="50">
<input name="inputAge" id="inputAge4" onkeyup="bmr();" type="text" width="50">
<input name="output" id="output" onkeyup="bmr();" type="text" width="100">
Can you figure out the error? Think getElementById()
okay, here's another hint:
<input name="inputInch" id="inputInch3" size="0" maxlength="4" type="text" width="50">
<input name="inputPound" id="inputPound4" maxlength="4" type="text" width="50">
<input name="inputAge" id="inputAge4" onkeyup="bmr();" type="text" width="50">
<input name="output" id="output" onkeyup="bmr();" type="text" width="100">
can you see it now?
You are using getElementById() correctly, but you are referring to the name of the <input> instead of the id
by the way, it is perfectly fine to use the same name and id in one input tag.
Anyways, for msie to work with the non-matching id just shows another incompetency of msie for "following (coughmsieonlycough) standards". Moreover, <input> tags should be inside <form>'s instead of out in the plain like that.
try adding <form> and </form> around the <table></table> that contains your input form. validate it and make less people cry ,)