html - HTML 模式验证 RegExp 在 chrome 中不起作用
问题描述
我在 Html 的模式属性中使用以下正则表达式来验证电子邮件。(type="email" 保留没有域扩展名的电子邮件)。
<input type="text" name="value" class="form-control" placeholder="Value" pattern="[-\w+.%]+@[\w-.]+\.[A-Za-z]{2,4}(?:,[-\w+.%]+@[\w-.]+\.[A-Za-z]{2,4}){0,4}"/>
但这在 chrome 中不起作用,但在 Internet Edge 浏览器中运行良好。谁能帮我解决这个问题?
解决方案
推荐阅读
- javascript - 单击注册按钮时,如何使注册表单在滑动登录/注册时静止?
- javascript - 添加溢出后宽下拉菜单被剪裁:滚动到侧边栏
- azure - Azure AD 应用程序 - 与用户连接的客户端密码
- shell - 我无法在我的虚拟机上启动 parrot os
- json - BotFramework-WebChat - 自适应卡片
- angular - Angular 8+ Observable - 更新基础价值的模式?
- python-3.x - unicode 打印 python 2 vs python 3
- r - R for循环计算wilcox.test
- javascript - javaScript:将一个函数分成两个
- angular - AWS Serverless Lambda + Angular - TypeError:express 不是函数