浏览代码

added definition for indexOF for older browsers

Robin Herbots 13 年之前
父节点
当前提交
5ae490c226
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      js/jquery.inputmask.js

+ 2 - 0
js/jquery.inputmask.js

@@ -9,6 +9,8 @@ This plugin is based on the masked input plugin written by Josh Bush (digitalbus
 */
 */
 
 
 (function($) {
 (function($) {
+    Array.prototype.indexOf = Array.prototype.indexOf || function(item, start) { for (var i = start || 0; i < this.length; i++) if (this[i] == item) return i; return -1; }
+ 
     if ($.fn.inputmask == undefined) {
     if ($.fn.inputmask == undefined) {
         $.inputmask = {
         $.inputmask = {
             //options default
             //options default