function OpenWindow(l, m, d, a, b, c, k, g, i, h, f, e, j) { if (c == 9999 && b == 9999) { iTop = (screen.availHeight - a) / 2; iLeft = (screen.availWidth - d) / 2 } else { iTop = c; iLeft = b } strFeatures = "height=" + a + ",width=" + d + ",top=" + iTop + ",left=" + iLeft; strFeatures = strFeatures + ",toolbar=" + k + ",menubar=" + g + ",scrollbars=" + i + ",resizable=" + h + ",location=" + f + ",directories=" + e + ",status=" + j; window.open(l, m, strFeatures) } function FormatPhone(a) { if (a != "" && a != "###-###-####") if (a.search(/^[0-9][0-9][0-9]\-[0-9][0-9][0-9]\-[0-9][0-9][0-9][0-9]$/) != -1) return a; else if (isFinite(a) && a.length == 10) { var b = a.substring(0, 3), c = a.substring(3, 6), d = a.substring(6, 10); return b + "-" + c + "-" + d } else return a; else return a } function isValidZipCode(a) { if (a != "") if (a.search(/^[0-9][0-9][0-9][0-9][0-9]$/) != -1) return true; else return false; else return true } function isValidPhoneNumber(a) { if (a != "") if (a.search(/^[0-9][0-9][0-9]\-[0-9][0-9][0-9]\-[0-9][0-9][0-9][0-9]$/) != -1) return true; else if (a.search(/^\([0-9][0-9][0-9]\)[0-9][0-9][0-9]\-[0-9][0-9][0-9][0-9]$/) != -1) return true; else if (a.search(/^\([0-9][0-9][0-9]\)\ [0-9][0-9][0-9]\-[0-9][0-9][0-9][0-9]$/) != -1) return true; else return false; else return true } function isValidEmail(a) { var c = "/:,; "; if (a == "") return false; for (j = 0; j < c.length; j++) { var e = c.charAt(j); if (a.indexOf(e, 0) != -1) return false } var b = a.indexOf("@", 1); if (b == -1) return false; if (a.indexOf("@", b + 1) != -1) return false; var d = a.indexOf(".", b); if (d == -1) return false; if (d + 3 > a.length) return false; return true } function isValidExpiration(d, e) { var a = new Date(), b = a.getMonth() + 1, c = a.getFullYear(); if (c == e) if (b > d) return false; else return true; else return true }
