PageSourceSearch

https://fukutomi-gas.com/contact/js/validation/exchecker-ja.js

js fukutomi-gas.com collected 2026-10-05 11:07:43 UTC 4,075 bytes, 160 lines download raw bytes

1/**
2 * exValidation
3 *
4 * @version   : 1.2.5
5 * @author    : nori ([email protected])
6 * @copyright : 5509 (http://5509.me/)
7 * @license   : The MIT License
8 * @link      : http://5509.me/log/exvalidation
9 * @modified  : 2011-08-14 01:52
10 */
11;(function($) {
12	// Extend validation rules
13	$.exValidationRules = $.extend($.exValidationRules, {
14		chkrequired: [
15			"入力してください",
16			function(txt, t) {
17				if ( $(t).hasClass("chkgroup") ) {
18					var flag = 0;
19					$("input,select",t).each(function() {
20						if ( $(this).val().length > 0 ) flag++;
21					});
22					if ( txt && flag === $("input,select", t).length ) {
23						if ( /^[  \r\n\t]+$/.test(txt) ) {
24							return false;
25						} else {
26							return true;
27						}
28					}
29				} else {
30					if ( txt && txt.length>0 ) {
31						if ( /^[  \r\n\t]+$/.test(txt) ) {
32							return false;
33						} else {
34							return true;
35						}
36					}
37				}
38			}
39		],
40		chkselect: [
41			"選択してください",
42			function(txt, t) {
43				if ( txt && txt.length>0 ) {
44					if ( /^[  \r\n\t]+$/.test(txt) ) {
45						return false;
46					} else {
47						return true;
48					}
49				}
50			}
51		],
52		chkretype: [
53			"入力内容が異なります",
54			function(txt, t) {
55				var elm = $("#" + $(t).attr("class").split("retype\-")[1].split(/\b/)[0]);
56				if ( elm.hasClass("chkgroup") ) {
57					var chktxt = $("input", elm), txt = $("input", t);
58					for ( var i = 0, flag = false; i < chktxt.length; i++ ) {
59						if ( chktxt[i].value === txt[i].value ) flag = true;
60						else flag = false;
61					}
62					if ( flag ) return true;
63				} else {
64					return elm.val() == txt;
65				}
66			}
67		],
68		chkemail: [
69			"正しいメールアドレスの形式を入力してください",
70			/^(?:[^\@]+?@[A-Za-z0-9_\.\-]+\.+[A-Za-z\.\-\_]+)*$/
71		],
72		chkhankaku: [
73			"全角文字は使用できません",
74			/^(?:[a-zA-Z0-9@\;\:\[\]\{\}\|\^\=\/\!\*\`\"\#\$\+\%\&\'\(\)\,\.\-\_\?\\\s]*)*$/
75		], //"
76		chkzenkaku: [
77			"全角文字で入力してください",
78			/^(?:[^a-zA-Z0-9@\;\:\[\]\{\}\|\^\=\/\!\*\"\#\$\+\%\&\'\(\)\,\.\-\_\?\\\s]+)*$/
79		], //"
80		chkhiragana: [
81			"ひらがなで入力してください",
82			/^(?:[ぁ-ゞ]+)*$/
83		],
84		chkkatakana: [
85			"カタカナで入力してください",
86			/^(?:[ァ-ヾ]+)*$/
87		],
88		chkfurigana: [
89			"ふりがなはひらがな、全角数字と〜、ー、()が利用できます",
90			/^(?:[ぁ-ゞ0-9ー~()\(\)\d  ]+)*$/
91		],
92		chknochar: [
93			"英数字で入力してください",
94			/^(?:[a-zA-Z0-9]+)*$/
95		],
96		chknocaps: [
97			"英数字(小文字のみ)で入力してください",
98			/^(?:[a-z0-9]+)*$/
99		],
100		chknumonly: [
101			"半角数字のみで入力してください",
102			/^(?:[0-9]+)*$/
103		],
104		chkmin: [
105			"文字以上で入力してください",
106			function(txt, t) {
107				if ( txt.length === 0 ) return true;
108			 	var length = $(t).attr("class").match(/min(\d+)/) ? RegExp.$1 : null;
109				return txt.length >= length;
110			}
111		],
112		chkmax: [
113			"文字以内で入力してください",
114			function(txt, t) {
115				var length = $(t).attr("class").match(/max(\d+)/) ? RegExp.$1 : null;
116				return txt.length <= length;
117			}
118		],
119		chkradio: [
120			"選択してください",
121			function(txt, t) {
122				return $("input:checked",t).length>0;
123			}
124		],
125		chkcheckbox: [
126			"選択してください",
127			function(txt, t) {
128				return $("input:checked",t).length>0;
129			}
130		],
131		chkurl: [
132			"正しいURLの形式を入力してください",
133			/^(?:http(s)?\:\/\/[^\/]*)*$/
134		],
135		chktel: [
136			"正しい電話番号を入力してください",
137			/^(?:\(?\d+\)?\-?\d+\-?\d+)*$/
138		],
139		chkfax: [
140			"正しいファックス番号を入力してください",
141			/^(?:\(?\d+\)?\-?\d+\-?\d+)*$/
142		],
143		chkzip: [
144			"半角で正しい郵便番号の形式を入力してください",
145			/^(?:\d{3}\-\d{4})*$/
146		],
147		chkfile: [
148			"ファイルを選択してください",
149			function(txt, t) {
150				if ( txt && txt.length>0 ) {
151					if ( /^[  \r\n\t]+$/.test(txt) ) {
152						return false;
153					} else {
154						return true;
155					}
156				}
157			}
158		]
159	});
160})(jQuery);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.