echo '<br>' . $x . '<br>'; echo 3 + "54rww" . "<br>"; function show() { global $sss; $sss = "uuuiii"; echo 'sss:' . $sss . '<br>'; } $cars = array("Volvo", "BMW", "Toyota"); var_dump($cars); echo '<br>'; ?> <?php $a = new A(); $a->show(); echo A::aa . '<br>'; class A { const aa = 'uuuu8888'; private $name = "eee"; public function show($value = "ddd") { echo "{$this->name} this is function show of class a {$value}<br>"; } } ?> <?php define("xx", "yyyyyyyyy", true); $xx = "yyyyyyyyy";
<?php interface MyInterface { function mycount(); } interface Another { function show(); } class A implements MyInterface, Another { function mycount() { return 17; } function show() { return $this->mycount(); } } //$myInterface = new MyInterface(); // Causes Fatal error_get_last $a = new A(); echo $a->show();
function show() { echo $this->action . "<hr>"; parent::show(); // TODO: Change the autogenerated stub }