Implementation of 17 regular expressions in PHP, php17 regular Expressions _php tutorial

Source: Internet
Author: User

Implementation of 17 regular expressions in PHP, php17 regular expressions


17 Regular expressions implemented in PHP

This tutorial is from: PHP Tutorial Web: http://php.662p.com

"^\d+[discuz_code_1]quot;  Non-negative integer (positive integer + 0) "^[0-9]*[1-9][0-9]*[discuz_code_1]quot; Positive integer "^ ((-\d+) | (  0+)) [Discuz_code_1]quot;  Non-positive integer (negative integer + 0) "^-[0-9]*[1-9][0-9]*[discuz_code_1]quot;    Negative integer "^-?\d+[discuz_code_1]quot; Integer "^\d+ (\.\d+)?  [Discuz_code_1]quot; Non-negative floating-point number (positive floating point + 0) "^ ([0-9]+\.[ 0-9]*[1-9][0-9]*) | ([0-9]*[1-9][0-9]*\. [0-9]+) | ([0-9]*[1-9][0-9]*))  [Discuz_code_1]quot; Positive floating point "^ ((-\d+ (\.\d+)?) | (0+ (\.0+)?))  [Discuz_code_1]quot; Non-positive floating-point number (negative floating-point number + 0) "^ (-([0-9]+\.[ 0-9]*[1-9][0-9]*) | ([0-9]*[1-9][0-9]*\. [0-9]+) | ([0-9]*[1-9][0-9]*)))  [Discuz_code_1]quot; Negative floating point "^ (-?\d+) (\.\d+)?  [Discuz_code_1]quot;  Floating point "^[a-za-z]+[discuz_code_1]quot;  A string consisting of 26 English letters "^[a-z]+[discuz_code_1]quot;  A string consisting of 26 uppercase letters "^[a-z]+[discuz_code_1]quot;     A string consisting of 26 lowercase letters "^[a-za-z0-9]+[discuz_code_1   ]quot;  A string consisting of a number and 26 English letters "^\w+[discuz_code_1]quot; A string consisting of numbers, 26 letters, or underscores "^[\w-]+ (\.[ \w-]+) *@[\w-]+ (\.[    \w-]+) +[discuz_code_1]quot; Email address "^[a-za-z]+://(\w+ (-\w+) *) (\. ( \w+ (-\w+) *) * (\?\s*)?    [Discuz_code_1]quot; Url

Detailed Description: http://php.662p.com/thread-532-1-1.html

http://www.bkjia.com/PHPjc/909084.html www.bkjia.com true http://www.bkjia.com/PHPjc/909084.html techarticle 17 Regular expressions are implemented in PHP, and there are 17 regular expressions implemented in PHP with PHP17 regular Expressions This tutorial is from: PHP Tutorial Web: http://php.662p.com "^\d+[discuz_code_1]quot; Non-negative integer ...

  • 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.