특정 이메일 입력 금지및 이메일 유효성 검사

· 17년 전 · 2142

daum, naver, yahoo,hanmail 계정은 입력할 수 없습니다<br>

<form name="validation" onSubmit="return checkbae()">
이메일 주소 입력 :
<input type="text" size=18 name="emailcheck"><br>
<input type="submit">
</form>

<script language="JavaScript1.2">

var invalidaddress=new Array()
invalidaddress[0]="daum"
invalidaddress[1]="naver"
invalidaddress[2]="yahoo"
invalidaddress[3]="hanmail"

var testresults
function checkemail(){
var invalidcheck=0;
var str=document.validation.emailcheck.value
var filter=/^(\w+(?:\.\w+)*)@((?:\w+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i
if (filter.test(str)){
var tempstring=str.split("@")
tempstring=tempstring[1].split(".")
for (i=0;i<invalidaddress.length;i++){
if (tempstring[0]==invalidaddress[i])
invalidcheck=1
}
if (invalidcheck!=1)
testresults=true
else{
alert("입력 금지된 계정입니다")
testresults=false
}
}
else{
alert("이메일 주소가 유효하지 않습니다")
testresults=false
}
return (testresults)
}
function checkbae(){
if (document.layers||document.getElementById||document.all)
return checkemail()
else
return true
}
</script>

[이 게시물은 관리자님에 의해 2011-10-31 16:57:14 JavaScript에서 이동 됨]
|
댓글을 작성하시려면 로그인이 필요합니다.

프로그램

태그 필터 (최대 3개) 전체 개발자 소스 기타 mysql 팁자료실 javascript php linux flash 정규표현식 jquery node.js mobile 웹서버 os 프로그램 강좌 썸네일 이미지관련 도로명주소 그누보드5 기획자 견적서 계약서 기획서 마케팅 제안서 seo 통계 서식 통계자료 퍼블리셔 html css 반응형 웹접근성 퍼블리싱 표준화 반응형웹 홈페이지기초 부트스트랩 angularjs 포럼 스크린리더 센스리더 개발자톡 개발자팁 퍼블리셔톡 퍼블리셔팁 기획자톡 기획자팁 프로그램강좌 퍼블리싱강좌
+
제목 글쓴이 날짜 조회
17년 전 조회 1,378
17년 전 조회 1,115
17년 전 조회 1,190
17년 전 조회 2,991
17년 전 조회 2,538
17년 전 조회 2,120
17년 전 조회 2,121
17년 전 조회 1,863
17년 전 조회 2,317
17년 전 조회 2,085
17년 전 조회 2,052
17년 전 조회 1,938
17년 전 조회 1,274
17년 전 조회 1,893
17년 전 조회 2,295
17년 전 조회 2,381
17년 전 조회 1,706
17년 전 조회 1,577
17년 전 조회 1,431
17년 전 조회 2,648
17년 전 조회 2,740
17년 전 조회 2,129
17년 전 조회 2,484
17년 전 조회 2,794
17년 전 조회 1,391
17년 전 조회 1,247
17년 전 조회 6,397
17년 전 조회 1,246
17년 전 조회 1,703
17년 전 조회 1,840
17년 전 조회 1,163
17년 전 조회 1,260
17년 전 조회 1,953
17년 전 조회 1,588
17년 전 조회 3,693
17년 전 조회 1,277
17년 전 조회 1,970
17년 전 조회 1,233
17년 전 조회 1,461
17년 전 조회 2,425
17년 전 조회 2,087
17년 전 조회 1,098
17년 전 조회 1,114
17년 전 조회 1,169
17년 전 조회 6,110
17년 전 조회 5,915
17년 전 조회 2,097
17년 전 조회 1,090
17년 전 조회 1,195
17년 전 조회 2,143
17년 전 조회 1,573
17년 전 조회 1,222
17년 전 조회 1,251
17년 전 조회 1,189
17년 전 조회 1,119
17년 전 조회 4,018
17년 전 조회 2,232
17년 전 조회 1,681
17년 전 조회 2,827
17년 전 조회 1,534
17년 전 조회 1,216
17년 전 조회 1,248
17년 전 조회 1,308
17년 전 조회 1,196
17년 전 조회 1,303
17년 전 조회 2,463
17년 전 조회 4,255
17년 전 조회 1,260
17년 전 조회 4,008
17년 전 조회 4,163
17년 전 조회 1,278
17년 전 조회 2,243
17년 전 조회 1,684
17년 전 조회 3,282
17년 전 조회 1,425
17년 전 조회 3,663
17년 전 조회 3,460
17년 전 조회 2,624
17년 전 조회 2,996
17년 전 조회 2,693
17년 전 조회 2,010
17년 전 조회 3,371
17년 전 조회 2,698
17년 전 조회 3,580
17년 전 조회 1,209
17년 전 조회 2,315
17년 전 조회 1,385
17년 전 조회 1,260
17년 전 조회 1,130
17년 전 조회 1,111
17년 전 조회 1,484
17년 전 조회 2,920
17년 전 조회 3,323
17년 전 조회 3,065
17년 전 조회 1,943
17년 전 조회 4,047
17년 전 조회 1,470
17년 전 조회 1,199
17년 전 조회 1,305
17년 전 조회 1,178