3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class Pippo { protected $nome; public function getNome() { return $this->nome; } public function __construct($nome) { $this->nome = $nome; } } $pippo = new Pippo('Pippo Baudo'); $propName = 'getNome'; print($pippo->{ $propName }()); $test = explode('|', 'value'); print($test[0]); print($test.length);
based on nfdku
Output for 7.2.0
Pippo Baudovalue Warning: Use of undefined constant length - assumed 'length' (this will throw an Error in a future version of PHP) in /in/FlUmU on line 22 Notice: Array to string conversion in /in/FlUmU on line 22 Arraylength
Output for 5.4.7 - 7.1.10
Pippo Baudovalue Notice: Use of undefined constant length - assumed 'length' in /in/FlUmU on line 22 Notice: Array to string conversion in /in/FlUmU on line 22 Arraylength
Output for 5.3.17 - 5.3.29
Pippo Baudovalue Notice: Use of undefined constant length - assumed 'length' in /in/FlUmU on line 22 Arraylength