How Used Validation IF two buttons on Form and Both validates different control

May 3, 2010 at 6:32 AM

How used validation IF two submit buttons on Form and Both validates different control.

Coordinator
May 7, 2010 at 11:53 AM

That's what the validate attribute is for, so in the same form you can have something like this:

<form>
    <input type="text" validate="group1" require="Please enter your desired username." />
    <input type="submit" value="Submit" onclick="return validate('group1');">

    <input type="text" validate="group2" require="Please enter your message." />
    <input type="submit" value="Submit" onclick="return validate('group2');">   
</form>

Does that help?