最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
asp检测email 的合法性程序
时间:2022-06-30 09:14:34 编辑:袖梨 来源:一聚教程网
function IsValidEmail(email)
dim names, name, i, c
IsValidEmail = true
names = Split(email, "@")
if UBound(names) <> 1 then
IsValidEmail = false
exit function
end if
for each name in names
if Len(name) <= 0 then
IsValidEmail = false
exit function
end if
for i = 1 to Len(name)
c = Lcase(Mid(name, i, 1))
if InStr("abcdefghijklmnopqrstuvwxyz_-.", c) <= 0 and not IsNumeric(c) then
IsValidEmail = false
exit function
end if
next
if Left(name, 1) = "." or Right(name, 1) = "." then
IsValidEmail = false
exit function
end if
next
if InStr(names(1), ".") <= 0 then
IsValidEmail = false
exit function
end if
i = Len(names(1)) - InStrRev(names(1), ".")
if i <> 2 and i <> 3 then
IsValidEmail = false
exit function
end if
if InStr(email, "..") > 0 then
IsValidEmail = false
end if
end function
相关文章
- 魔兽世界暗影界飞行怎么解锁-10.0暗影界飞行解锁攻略 07-10
- 逆水寒手游最新118个绑凿获取攻略 07-10
- 比特币软件从哪里下载?比特币交易软件推荐附带下载 07-10
- 赞美环境优美的话语精选90句 07-10
- 胜利女神新的希望尼尔联动有什么 2BA2角色获取方法 07-10
- Aptos双底形态指向10美元看涨目标 - 详情 07-10