mpower Posted May 15, 2007 Share Posted May 15, 2007 Normaly I validate forms with PHP or other middle ware languages. But in this case I need to do it with JavaScript. Problem is that I'm not very good at it. Maybe someone is able to help me a bit? I need to "validate" a form on the response page. Let me describe an easy example for what I'm trying to accomplish. I got two checkboxes in the form - one named "A" and the other "B". On the response page it should check wich one of the checkboxes that was checked and if it was "A" it shell output 1, if it was "B" it shell output 2 or if both where checked it shell output "Error". Does anyone know how to accomplish this? Thanks in advance // Jonas Quote Link to comment Share on other sites More sharing options...
simon551 Posted May 15, 2007 Share Posted May 15, 2007 There are some pretty good tutorials on w3cschools.com basically you will need an event that triggers a function which then checks the value and returns a result Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.