Microsoft JScript运行时错误:'this.Plugins [...]'为null或不是对象
来自此代码:
var xVal = xVal || {
Plugins: {},
AttachValidator: function(elementPrefix, rulesConfig, pluginName) {
if (pluginName != null)
this.Plugins[pluginName].AttachValidator(elementPrefix, rulesConfig);
else
for (var key in this.Plugins) {
this.Plugins[key].AttachValidator(elementPrefix, rulesConfig);
return;
}
}
};
答案 0 :(得分:1)
确保在母版页中引用 xVal.AspNetNative.js 和 xVal.jquery.validate.js 。