当前位置:网站首页>The registration password of day 239/300 is 8~14 alphanumeric and punctuation, and at least 2 checks are included
The registration password of day 239/300 is 8~14 alphanumeric and punctuation, and at least 2 checks are included
2022-07-06 06:40:00 【Arden Zhao】
( One ) demand
The registration password should be verified , The requirement is :
- The length is 8~14 Characters
- Alphanumeric and punctuation symbols shall contain at least 2 Kind of
- No Spaces allowed 、 chinese
( Two ) Ideas
1、 Each condition is checked separately
- The length is 8~14 Characters
str.length
- Alphanumeric and punctuation symbols shall contain at least 2 Kind of
- No Spaces allowed 、 chinese
2、 Regular check
const rules = /(?!^[0-9]+$)(?!^[A-z]+$)(?!^[^A-z0-9]+$)^[^\s\u4e00-\u9fa5]{8,14}$/
if (!rules.test(value)) {
return Promise.reject(' The length is 8~14; Alphanumeric and punctuation symbols shall contain at least 2 Kind of ; No Spaces allowed 、 chinese ')
}
( 3、 ... and ) Other regularities used
1、 cell-phone number
const phone = /^1(3\d|4[5-9]|5[0-35-9]|6[2567]|7[0-8]|8\d|9[0-35-9])\d{8}$/
if (!phone.test(this.form.account)) {
message.warning(' The phone number format is incorrect ')
return
}
2、 mailbox
const email = /^\w+(\.)?(\w+)[email protected][0-9a-z]+(\.[a-z]+){1,3}$/
if (!email.test(this.form.account)) {
message.warning(' The email format is incorrect ')
return false
}
Write it at the end
On the way to study , Often slack off
《 There are students who want to learn technology and need supervision ~》
https://mp.weixin.qq.com/s/FyuddlwRY7DsHUejCjiVug
边栏推荐
- Py06 字典 映射 字典嵌套 键不存在测试 键排序
- 利用快捷方式-LNK-上线CS
- Facebook AI & Oxford proposed a video transformer with "track attention" to perform SOTA in video action recognition tasks
- SourceInsight Chinese garbled
- My seven years with NLP
- MFC on the conversion and display of long string unsigned char and CString
- Black cat takes you to learn UFS protocol Chapter 4: detailed explanation of UFS protocol stack
- LeetCode 1200. Minimum absolute difference
- 商标翻译有什么特点,如何翻译?
- Office-DOC加载宏-上线CS
猜你喜欢

SQL Server manager studio(SSMS)安装教程

The ECU of 21 Audi q5l 45tfsi brushes is upgraded to master special adjustment, and the horsepower is safely and stably increased to 305 horsepower

Data type of MySQL

SQL Server Manager studio (SSMS) installation tutorial

Thesis abstract translation, multilingual pure human translation
![[ 英語 ] 語法重塑 之 動詞分類 —— 英語兔學習筆記(2)](/img/3c/c25e7cbef9be1860842e8981f72352.png)
[ 英語 ] 語法重塑 之 動詞分類 —— 英語兔學習筆記(2)

(practice C language every day) reverse linked list II

Today's summer solstice

详解SQL中Groupings Sets 语句的功能和底层实现逻辑

翻译影视剧字幕,这些特点务必要了解
随机推荐
Fledgling Xiao Li's 103rd blog CC2530 resource introduction
Tms320c665x + Xilinx artix7 DSP + FPGA high speed core board
Leetcode daily question (1997. first day where you have been in all the rooms)
自动化测试环境配置
The ECU of 21 Audi q5l 45tfsi brushes is upgraded to master special adjustment, and the horsepower is safely and stably increased to 305 horsepower
How effective is the Chinese-English translation of international economic and trade contracts
详解SQL中Groupings Sets 语句的功能和底层实现逻辑
Redis core technology and basic architecture of actual combat: what does a key value database contain?
Leetcode daily question (971. flip binary tree to match preorder traversal)
如何做好互联网金融的英语翻译
英语论文翻译成中文字数变化
关于新冠疫情,常用的英文单词、语句有哪些?
论文摘要翻译,多语言纯人工翻译
[web security] nodejs prototype chain pollution analysis
Use shortcut LNK online CS
Black cat takes you to learn UFS protocol Chapter 18: how UFS configures logical units (Lu Management)
CS-证书指纹修改
【MQTT从入门到提高系列 | 01】从0到1快速搭建MQTT测试环境
Number of query fields
mysql按照首字母排序