function _check_email(email) {
var pattern = /^(.+)@(.+)$/;
var atom = "\[^\\s\\(\\)<>#@,;:!\\\\\\\"\\.\\[\\]\]+";
var word="(" + atom + "|(\"[^\"]*\"))";
var user_pattern = new RegExp("^" + word + "(\\." + word + ")*$");
var ip_pattern = /^\[(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})\]$/;
var domain_pattern = new RegExp("^" + atom + "(\\." + atom +")*$");
var arr = email.match(pattern);
if (!arr) return "Email address seems incorrect (check @ and .'s)";
if (!arr[1].match(user_pattern)) return "The username doesn't seem to be valid.";
var ip = arr[2].match(ip_pattern);
if (ip) {
for (var i=1; i<5; i++) if (ip[i] > 255) return "Destination IP address is invalid!";
}
else {
if (!arr[2].match(domain_pattern)) return "The domain name doesn't seem to be valid.";
var domain = arr[2].match(new RegExp(atom,"g"));
if (domain.length<2) return "This address is missing a hostname!";
if (domain[domain.length-1].length<2 || domain[domain.length-1].length>3)
return "The address must end in a three-letter domain, or two letter country.";
}
return false;
}<div class='small'>[이 게시물은 관리자님에 의해 2011-10-31 16:57:14 JavaScript에서 이동 됨]</div>
var pattern = /^(.+)@(.+)$/;
var atom = "\[^\\s\\(\\)<>#@,;:!\\\\\\\"\\.\\[\\]\]+";
var word="(" + atom + "|(\"[^\"]*\"))";
var user_pattern = new RegExp("^" + word + "(\\." + word + ")*$");
var ip_pattern = /^\[(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})\]$/;
var domain_pattern = new RegExp("^" + atom + "(\\." + atom +")*$");
var arr = email.match(pattern);
if (!arr) return "Email address seems incorrect (check @ and .'s)";
if (!arr[1].match(user_pattern)) return "The username doesn't seem to be valid.";
var ip = arr[2].match(ip_pattern);
if (ip) {
for (var i=1; i<5; i++) if (ip[i] > 255) return "Destination IP address is invalid!";
}
else {
if (!arr[2].match(domain_pattern)) return "The domain name doesn't seem to be valid.";
var domain = arr[2].match(new RegExp(atom,"g"));
if (domain.length<2) return "This address is missing a hostname!";
if (domain[domain.length-1].length<2 || domain[domain.length-1].length>3)
return "The address must end in a three-letter domain, or two letter country.";
}
return false;
}<div class='small'>[이 게시물은 관리자님에 의해 2011-10-31 16:57:14 JavaScript에서 이동 됨]</div>
게시글 목록
| 번호 | 제목 |
|---|---|
| 32341 | |
| 32339 | |
| 32326 | |
| 32325 | |
| 32322 | |
| 32319 | |
| 32318 | |
| 32316 | |
| 32315 | |
| 32313 | |
| 32312 | |
| 32311 | |
| 32310 | |
| 32304 | |
| 32303 | |
| 32300 | |
| 32293 | |
| 32292 | |
| 32291 | |
| 32285 | |
| 32284 | |
| 32275 | |
| 32271 | |
| 32268 | |
| 32265 | |
| 32261 | |
| 32258 | |
| 32257 | |
| 32255 | |
| 32254 | |
| 32253 | |
| 32251 | |
| 32250 | |
| 32249 | |
| 32247 | |
| 32246 | |
| 32245 | |
| 32244 | |
| 32243 | |
| 32242 | |
| 32241 | |
| 32240 | |
| 32239 | |
| 32238 | |
| 32237 | |
| 32236 | |
| 32232 | |
| 32229 | |
| 32228 | |
| 32227 | |
| 32217 | |
| 32215 | |
| 32214 | |
| 32213 | |
| 32211 | |
| 32207 | |
| 32196 | |
| 32193 | |
| 32192 | |
| 32190 | |
| 32188 | |
| 32186 | |
| 32184 | |
| 32173 | |
| 32172 | |
| 32171 | |
| 32167 | |
| 32165 | |
| 32163 | |
| 32162 | |
| 32158 | |
| 32157 | |
| 32155 | |
| 32151 | |
| 32149 | |
| 32135 | |
| 32132 | |
| 32127 | |
| 32125 | |
| 32122 | |
| 32120 | |
| 32119 | |
| 32117 | |
| 32116 | |
| 32115 | |
| 32114 | |
| 32112 | |
| 32111 | |
| 32109 | |
| 32107 | |
| 32104 | |
| 32103 | |
| 32102 | |
| 32101 | |
| 32094 | |
| 32089 | |
| 20404 | |
| 31036 | |
| 8279 | |
| 8268 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기