This project is read-only.

jquery form validation

Feb 9, 2011 at 8:14 AM
Edited Feb 9, 2011 at 8:20 AM

Do you have a jquery plugin example in wish form validation is possible. Or do i have to create javascript without jquery myself?

Feb 9, 2011 at 7:52 PM

mdo:submit, mdo:ajax can accept js function name as validator:

<script type="text/javascript" 
  src="" />
<script type="text/javascript">
  function validateForm() {
    return $("form").validate().form();

<div>Name: <input name="qqqq" class="required" /></div>
<div>E-Mail: <input name="aaaa" class="required email" /></div>

<a href="{mdo:jsubmit('validateForm', '@action', 'save')}">Save</a>

Validator must return false if errors occure, false otherwise.