1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81
|
<?php
// True
function myFunction($arg1, $arg2=TRUE)
{
}
function myFunction($arg1, $arg2=TRUE)
{
}
function myFunction($arg1, $arg2=TRUE)
{
}
if ($variable === TRUE) { }
if ($variable === TRUE) { }
if ($variable === TRUE) { }
// False
function myFunction($arg1, $arg2=FALSE)
{
}
function myFunction($arg1, $arg2=FALSE)
{
}
function myFunction($arg1, $arg2=FALSE)
{
}
if ($variable === FALSE) { }
if ($variable === FALSE) { }
if ($variable === FALSE) { }
// Null
function myFunction($arg1, $arg2=NULL)
{
}
function myFunction($arg1, $arg2=NULL)
{
}
function myFunction($arg1, $arg2=NULL)
{
}
if ($variable === NULL) { }
if ($variable === NULL) { }
if ($variable === NULL) { }
$x = new stdClass();
$x->null = 7;
use Zend\Log\Writer\Null as NullWriter;
new \Zend\Log\Writer\Null()
namespace False;
class True extends Null implements False {}
use True\Something;
use Something\True;
class MyClass
{
public function myFunction()
{
$var = array('foo' => new True());
}
}
$x = $f?FALSE:TRUE;
$x = $f? FALSE:TRUE;
class MyClass
{
// Spice things up a little.
const true = FALSE;
}
var_dump(MyClass::true);
function true() {}
|