- var_dump: documentation ( source)
- define: documentation ( source)
<?php
class Example {
const FOO = 'bar';
public function __construct($b)
{
define('BAR', 'foo');
$this->FOO = $b;
}
}
$example = new Example('hippy');
var_dump($example::FOO);