我确定我在某个地方遗漏了一些东西,但我看不到在哪里。我正在尝试使用 jQuery 验证脚本,但不断收到此错误。我很确定所有文件都在正确的位置等。这是在头:
<script src="scripts/jquery.min.js"></script>
<script src="scripts/jquery.validate.min.js"></script>
<script>
$(document).ready(function() {
$('#form1').validate();
}); // end ready
</script>
那么我的表格如下:
<p>
<label for="name">Your name:
</label><br />
<input name="name" type="text" class="required" title="Please enter your name." id="name" maxlength="80" />
</p>
<p>
<label for="email">Your email address:</label><br /><input name="email" type="text" class="required email" title="Please enter a valid email address." id="email" maxlength="100" />
</p>
<p>
<label for="phone">Your contact number:</label><br />
<input name="phone" type="text" class="required" title="Please enter your phone number" id="phone" maxlength="50" />
</p>
<p>
<label for="message">Message:<br />
</label>
<textarea name="message" id="message" cols="50" rows="5"></textarea>
</p>
<p>
<input name="Submit" type="submit" class="form" id="Submit" value="Submit" style="width:100px" />
</p>
</form>
谢谢你的帮助!