Recent projects with the need to call the real-name authentication interface, real-name authentication interface price is not a few cents higher than the text message, so call the real-names authentication conditions to strictly check, so the use of JS to verify the real title and JS Authentication ID number.Go to the ChaseJS to verify the real name, is to use the Unicode character to match, and the Chinese
= document.getElementById (' Iputcode '). Value; Obtain the verification code that the registered user fills invar yzmtwo = document.getElementById (' Iputcode '). ClassName; Verification code sent by the systemif (Yzm = = "") {Alert ("Verification code cannot be empty");return false;}else if (yzm! = yzmtwo) {Alert ("Verification code error, please re-enter!") ");Eturn false;}return true;}Click Next to verify that the verification code is correct$ (f
Here is the regular expression that the mobile official pulled down:Determine if a string is a mobile phone number0 is the cell phone number 1 is not the 11 digit number 2nd code prefix is incorrectUsed to verify the number of digits in the mobile phone number and check whet
This article brings you the content is about PHP activity how to verify whether the user is concerned about the public number, there is a certain reference value, the need for friends can refer to, I hope to help you.
When we do activities, some activities require users to pay attention to the public number in order to continue activities or send gifts. This re
code example to verify phone number format:In some forms you need to verify the phone format is correct, of course, there are many ways to verify, the following is a common code.The code is as follows:functionIsMobile (MOBILE) {if(mobile.length!=11) {alert (' Please enter a valid mobile phone
In some personnel information system, may ask to fill in the person's identity card number, but how to verify the format of the ID number is legal? We write the validated SQL as a stored procedure to facilitate repeated calls.First of all, we need to understand the composition of our identity number rules:1, 18-digit I
Jquery Regular Expression verification: Verify that the number is 12 bits, jquery Regular Expression
Requirement Description:
The front-end page uses regular expressions to verify that the input data is a 12-digit number.
Code Description:
Only regular expressions are introduced here, and other parts of the Code ar
/*** Convert dates to YYYY-MM format.* Help verify that two times are in the same year of the month* @param datestr*/function Formatyearmonth (b_date) {var b_date_year = B_date.getyear ();var b_date_month = B_date.getmonth () +1;if (B_date_month B_date_month = "0" + b_date_month;}return b_date_year + "" + b_date_month;}function Getdatesub (date_b,date_e) {The following must have, otherwise it will be but a Nanvar b_date = new Date (Date.parse (Date_b.
Provides various official and user-released code examples. For code reference, you are welcome to learn how to verify that the ID card number entered by the user is valid?
Most of the verification methods on the Internet only perform a simple verification of the ID card number format, and do not verify the validity of
Use the js regular expression to verify the mobile phone number, email address, and zip code. If you want to verify your mobile phone number, you can refer to it for reference. (11 digits are entered at the beginning of "13" and "158,159)
The Code is as follows:
Var re;Var ss = document. getElementById ('textbox3 ').
: A numeric value representing the ID number at position i
Wi: Indicates the weighting factor at position I
Wi:7 9 10 5 8 4 2 1 6 3 7 9 10 5 8 4 2
2. Calculation mode
Y = mod (S, 11)
3. Get the corresponding check code by the module
Y:0 1 2 3 4 5 6 7 8 9 10
Check code: 1 0 X 9 8 7 6 5 4 3 2
To verify the ID number method:
This article explains how to use PHP to
Asp.net has a verification control to help us verify the data in the form. Below we will explain an example of digital verification to give us a rough understanding of the validation control in Asp.net.
Step 1: Add the following controls to the page:
One Textbox (ID is the default textbox1), one button (ID is the default button1), one requiredfieldvalidator (verify and fill in), and one regularexpress
PHP verifies that the credit card number is the correct function
This article mainly introduces the PHP verification credit card number is the correct function, this article directly give implementation code, the need for friends can refer to the next
You can use the following PHP functions to verify whether a card number
Verify the mobile phone number in ASP. net mvc, asp. netmvc
In ASP. net mvc, you can use the RegularExpression feature to verify the mobile phone number.
public class Customer {[Required (ErrorMessage = "Required")][Display (Name = "mobile phone number")][RegularExp
This article mainly introduces the PHP implementation can accurately verify the identity card number of the tool class, involving PHP for string interception, calculation, judgment and other related operational skills, and accompanied by a description of the principle of the ID number, the need for friends can refer to the next
The example in this paper describe
appear m times;
{0,n} indicates that the decorated object appears at most n times and appears at least 0 times;
{m,} indicates that the decorated object appears at least m times.
2 is the length really only 11?
Observe the code in the following GIF to see that when the input string is a number with a length of 15, you can also match the first 11 digits. Even when the input character is abcd180123412341234, it can be matched to 11 digits.
Th
/********************Function Name: Istelephonefunction function: fixed, mobile phone number check function, return True, reverse, return falsefunction parameters: obj, number to be checkedCheck rule:(1) Number, "(", ")" and "-"(2) The phone number is 3 to 8 digits(3) If the phone
Use javascript to verify the mobile phone number and implement asterisks (*) to replace the instance, and use javascript asterisks
I. use JavaScript to replace four digits in the middle of the mobile phone number
// Match the beginning and end of the mobile phone number, and output '123' in a format similar to "123 ***
Provides various official and user-released code examples. For code reference, you are welcome to exchange and learn common regular expressions to verify information, such as the website email phone number.
/*** Common regular expressions are used to verify information, such as the mobile phone number of the website
Transfer from Http://blog.csdn.net/zheng963/article/details/49299993//Description: Bank card number Luhm check //luhm Check rule: 16-digit bank card number (19-bit universal): //1.15 (or 18) bit card numbers without check digit are numbered 1 through 15 (18) from right, multiplied by the number on the odd digit number
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.