PHP 0 differs from empty _php tutorial

Source: Internet
Author: User
As a qualified PHP programmer, some basic knowledge is necessary to know, such as the difference between 0 and empty, about this difference, the following through a few examples of simple analysis, in which the truth, imaginative achievement here, inexpressible, the reader can go slowly experience.

 
  In PHP, 0 is empty '; is output}if ($test = = = ") {echo ')
In PHP, 0 is empty '; not be output}if ($test ==null) {echo '
In PHP, 0 is empty '; Output}if ($test ===null) {echo '
In PHP, 0 is empty '; not be output}if ($test ==false) {echo '
In PHP, 0 is empty '; Output}if ($test ===false) {echo '
In PHP, 0 is empty '; not be output}?>

Articles you may be interested in

    • Usage and differences in PHP that jump out of multiple loops using Break,continue,goto,return,exit
    • Differences in PHP after adding the static keyword to variables and functions
    • The usage and difference of echo,print,print_r,var_export,var_dump in PHP
    • PHP empty,is_null,isset The difference between the detailed
    • The difference between execute and query methods in thinkphp
    • The difference and usage of return and exit, break and Contiue in PHP
    • PHP Merge array + vs. Array_merge
    • Differences between synchronous requests and asynchronous requests in HTTP requests

http://www.bkjia.com/PHPjc/764081.html www.bkjia.com true http://www.bkjia.com/PHPjc/764081.html techarticle as a qualified PHP programmer, some basic knowledge is necessary to know, such as the difference between 0 and empty, about this difference, the following through a few examples of simple analysis, wherein the ...

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