I want a combo checkbox to be used in validation, but won't work..
I created a form to look exactly as I wanted. Then when it came time to insert the registration form results in the database, the page fails to do the insert. Instead, it shows the registration form with all the fields filled in as they had been except the bottom of the form where I require a person to click a box indicating they accept t&cs and the Captcha and Security question field is blank but there's an error showing that the terms must be accepted (this is the failed validation message).
I used a combo box to get around the label appearing on the left side instead of the right side per a suggestion on the forum. I have one box with the value of the box showing "I accept..." and had it set to validate.
I had the insert failure and decided to make it not a required field. When I did that, it now does the insert OK. One way I tried to get around making it still a required field using the combo box was to set the min/max selections to one, but keep the validate unchecked.
Does this sound reasonable? Fact is it won't submit without the box being checked, but seems like just having the box validated with no min/max selections would have been good enough. It wasn't though.
The only thing I don't like is that box seems to be pre-checked whereas I want the person to select it intentionally. Another problem is the error message which shows that a value must be selected. This is the wrong validation message for what I'm wanting to do. I'd rather say "You must agree before continuing.."
The whole problem here is that I can't select which side the label would appear on a standard checkbox. Using the combo checkbox is a way of getting around the problem but it creates others. The only choice I have is to manually make changes to the code but I'd really rather not do that if possible since I'm trying to avoid doing stuff manually and then overwriting it. Is this my only choice?
steve