$scope.sendMail = function () {

            // console.log($scope.inputValue.inputEmail);

            //校验邮箱格式是否正确

            if (!$scope.inputValue.inputEmail) {

                alert({ type: '', title: '温馨提示', msg: '请输入您的邮箱地址' });

                return;

            } else {

                var reg = /^([a-zA-Z0-9]+[_|\_|\.]?)*[a-zA-Z0-9]+@([a-zA-Z0-9]+[_|\_|\.]?)*[a-zA-Z0-9]+\.[a-zA-Z]{2,3}$/; //正则表达式

                if (!reg.test($scope.inputValue.inputEmail)) {

                    alert({ title: '温馨提示', msg: '邮箱格式有误,请检查' });

                    return false;

                }

            }
}

最新文章

  1. Linux不使用useradd创建用户
  2. linux下如何使用sftp命令【转】
  3. jsp,图片显示
  4. LinQ To Object 基本用法
  5. Ionic学习笔记四 一些问题处理
  6. lua 的 WriteFile 和 ReadFile
  7. 超越luabind的luaBridge
  8. delphi列表视图组件(TListView)使用方法|实例
  9. Nodejs学习笔记——Assert(断言)
  10. Break the Chocolate(规律)
  11. NOI2007 生成树计数
  12. java IO 类库的基本架构
  13. flask项目开发中,遇到http 413错误
  14. [css 实践篇] 解决悬浮的<header> <footer>遮挡内容的处理技巧
  15. AI deeplab
  16. Openvswitch手册(8): ovs-vsctl的DB的操作
  17. 错误解决记录------------mysql连接本地数据库显示"can't get hostname for your address"
  18. 【二分】Producing Snow @Codeforces Round #470 Div.2 C
  19. golang string int int64转换
  20. Druid介绍2

热门文章

  1. pikachu-搜索型注入 #手工注入
  2. idea使用vue项目
  3. 树莓派Ubuntu Mate 16.04 修改为国内更新源
  4. httpClient简单封装
  5. 有未经处理的异常: 0xC00000FD: Stack overflow
  6. Passive Client Feature
  7. bootstrap-suggest-plugin input可选可输(表单) 好用的前端插件
  8. python2.7 安装 Scipy
  9. Ubantu 固定IP
  10. 02使用GitHub远程仓库