对象不支持此属性或方法 - Javascript错误

时间:2011-02-11 10:35:33

标签: javascript jquery internet-explorer

我已经查看了从此错误部分发布的一些问题,但我找不到真正的匹配。所以我再次寻求SO社区的支持。

我为bassistance validate plugindocs)收到了此错误。

代码

jQuery("#formTest").validate({
            rules: {
                event_title: "required",
                calendar1: "required",          
                calendar2: "required",
                event_venue: "required",
                event_des: "required",
                event_access: "required",
                event_email: {required: true,email: true},
                imagesrc:"required"
            },
            messages: {
                event_title: "Please enter the event title",
                calendar1: "Please select the start date",          
                calendar2: "Please select the end date",
                event_venue: "Please enter the event venue",
                event_des: "Please enter the event description",
                event_access: "Please choose one access option",
                event_email:"Please enter valid email address",
                imagesrc:"Please upload image"
            }
        });

1 个答案:

答案 0 :(得分:0)

此错误的最可能原因是您没有引用jQuery javascript文件...

<script type="text/javascript" src="jquery.min.js"></script>

如果您没有包含该脚本,则对于对jQuery框架的任何调用都会出现此错误。