Stop shouting "who gave me an ID number to verify the code", the script house webmaster provided the _ Application skills

Source: Internet
Author: User
Tags generator

QQ Group of brothers asked "who gave me an ID card number to verify the code" Just I also need to find the next code from the Internet, feel good, suitable for 15 and 18 ID card, online good garbage station, are directly collected csdn problem, the answer is no, Han
Use JavaScript to verify 15 or 18 ID card number, the most outrageous thing, unexpectedly someone search me a identity card number, give me an ID card look like everyone is very strong ah, it is possible that everyone is to have an ID generator it, OK, I provide the next bar

Copy Code code as follows:

function Checkidcard (str)
{//ID card Regular expression (15-bit)
Isidcard1=/^[1-9]\d{7} ((0\d) | ( 1[0-2])) (([0|1|2]\d) |3[0-1]) \d{3}
$/;
Identity card Regular expression (18-bit)
Isidcard2=/^[1-9]\d{5}[1-9]\d{3} ((0\d) | ( 1[0-2])) (([0|1|2]\d) |3
[0-1]) \d{4}$/;
Verify ID, return result
Return (Isidcard1.test (str) | | Isidcard2.test (str));
}

The following is an ID generator ah, illegal things ah, want to find me ah, please do not engage in illegal

Good thing, I checked, really, it's amazing.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.