Comments (15)
可以, 但是我第一次听说vin, 你简答说下格式要求, 我也百度下格式
from any-rule.
车架号啊, 是要匹配国际, 还是只要**即可?
from any-rule.
应该是国际标准,公司有一些进口车
示例 : 1G1BL52P7TR115520
信息为:1996年、GM(或Suzuki)、产地:美国。
tonylei
May 17 2006, 12:18 PM
from any-rule.
好的, 我写下, 等会 🐳
from any-rule.
好的,谢谢您了
from any-rule.
https://jingyan.baidu.com/album/5bbb5a1b1dad7413eaa1796e.html?picindex=2
这个规则有没有精准的说明, 看了几个感觉都不一样呢, 不知道那个对, 而且感觉好像都不对, 我先教你几个关键的知识点, 如果你对他的规则很了解你先自己试试,下面的知识点应该就够了, 我也在仔细看下他的规则:
/^[1-6,9,w,t]$/ // 匹配1到6和9和w和t
/[0-9,A-Z]/ // 匹配数字和大写字母
/^[^1]$/ // 不包含数字1
from any-rule.
嗯,好的,谢谢您了
from any-rule.
https://blog.csdn.net/shenhonglei1234/article/details/53103161
https://blog.csdn.net/ajianchina/article/details/70227234
这规则我是真没看明白, 我现在给你一个校验了位数/第一位国家编码的正则, 看看够不够你们用:
/^[1-6,9,J,K,L,R,S,T,V,W,Y,Z][0-9,A-Z,a-z]{16}$/.test('1G1BL52P7TR115520') // true
from any-rule.
我想起了手机号的正则, 之前做过调查, 很多人因为怕录入不进去都只是匹配11为数字即当做手机号, 至于手机号是否合法都交给了后端在数据库中验证 ,你这个是不是也一样呢?
https://juejin.im/pin/5d1ea9b6518825026ec4c5c7
from any-rule.
前后端都要校验,这个vin我也不太懂,应该够用了,真是麻烦您了,谢谢您
from any-rule.
客气客气, 我本来想给你写全面点的, 但是真是没读懂vin的规则.. 🐳
from any-rule.
我昨天看了一天,它这个有不同的说法,没有准确的信息,做起来有难度
from any-rule.
我看好像有个校验位还要做"余数"计算, 那个正则恐怕做不了.
既然后端也验证, 为了保险起见, 我建议用这条:
/^[0-9,A-Z,a-z]{17}$/.test('1G1BL52P7TR115520') // true
万一哪天哪个小国加入了呢...
from any-rule.
好的,麻烦您了,谢谢
from any-rule.
客气 🐳
from any-rule.
Related Issues (20)
- 我有更好的正则: 密码强度校验,最少6位,包括至少1个大写字母,1个小写字母,1个数字,1个特殊字符 HOT 1
- 正则表达式校验金额最多保留两位小数
- 我有更好的正则: 中文姓名 HOT 6
- 手机号校验规则(严谨)不适用了😭 HOT 6
- /^[GCDZTSPKXLY1-9]\d{1,4}$/
- 少数民族名字总会有"·"
- 我有更好的正则: 混合英文字母大小写、数宇、符号(排除@#%$^&*0)中的3种或以上
- 我有更好的正则: 手机号(mobile phone)**(严谨), 根据工信部2019年最新公布的手机号段 HOT 1
- 我有更好的正则: 手机号(mobile phone)**(严谨), 根据工信部2019年最新公布的手机号段 HOT 1
- 我有更好的正则: 网址(URL)
- 我有更好的正则: **身份证
- 我有更好的正则: 火车车次
- 能不能搞个表情符号的啊,这个网上一大堆用了都不对
- 我有更好的正则: 手机机身码(IMEI) HOT 1
- 我有更好的正则:手机号(严谨)
- 银行卡号校验错误❌(10到30位, 覆盖对公/私账户)河北省的对公账户匹配不上
- 我有更好的正则: 网址(URL)
- 增加特种汽车的车牌号有校验
- 我有更好的正则: ip-v4[:端口]
- 我有更好的正则: 日期(严谨, 支持闰年判断)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from any-rule.