Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
12-29-2005, 07:15 PM #1
- Join Date
- Dec 2005
- Thanked 0 Times in 0 Posts
Radio button validation and focus help needed
I am coding up a questionnaire in Domino 6.5.4. I am trying to validate all fields and when not succesful return an errror message and a subsequent focus to the field in question. Within the form there is a button that calls a dosubmit function located in the jsheader field. All works well except for two areas :
1 When trying to ensure that the a radio button has been selected (ie the question answered) the validation does not seem to be working. After many tinkerings with the syntax (value==null, checked==false) I still dont seem to be getting this to work (it either accepts the form in the browser or returns the error message advising that the field is still blank (in the case below the error is "please enter frequency"). My feeling is that my syntax is incorrect on this one so if someone could set this tired head straight it would be appreciated.
2 When returning the focus to the radio button in question in the browser it leaves out the text appearing above - essentially the question located two lines above. I realise that the focus is due to my selecting  -- (  being the first option in the radio button). Was wondering if there was any way to get the lines above to appear. the question is in text format and not a field so I can't ask for the focus to go to that field. I would just like a little more text appearing above. the code follows below and any help would be much appreciated as I think I am getting circular and not seeing the wood for the trees !!!
JS Header :
alert("Please enter your first name");
alert("Please enter your surname ");
alert("Please enter frequency ");
12-29-2005, 10:29 PM #2
- Join Date
- Mar 2005
- Portsmouth UK
- Thanked 506 Times in 493 Posts
Last edited by vwphillips; 12-29-2005 at 10:30 PM. Reason: code tags