3v4l.org

run code in 300+ PHP versions simultaneously
<?php class test { private $json; private $config; private $xmlFiles; private $modifiedElement; private $modifiedElement2; private $exchangeValue; private $exchangeValue2; private $inputFolderPath; private $outputFolderPath; private $outputFileName; public function __construct() { //$this->setXmlFiles(); //$this->createFolder(); $this->json = '{ "modifiedElement1" : "11", "modifiedElement2" : "22", "exchangeValue1" : "11", "exchangeValue2" : "333", "inputFolderPath" : "input/", "outputFolderPath" : "output/" }'; $this->config = json_decode($this->json); $this->xmlFiles = array(); $this->modifiedElement = $this->config->modifiedElement1; $this->modifiedElement2 = $this->config->modifiedElement2; $this->exchangeValue = $this->config->exchangeValue1; $this->exchangeValue2 = $this->config->exchangeValue2; $this->inputFolderPath = $this->config->inputFolderPath; $this->outputFolderPath = $this->config->outputFolderPath; $this->outputFileName = null; var_dump($this); } } $x = new test();
Output for 7.4.0 - 7.4.33, 8.0.1 - 8.0.30, 8.1.0 - 8.1.34, 8.2.0 - 8.2.30, 8.3.0 - 8.3.29, 8.4.1 - 8.4.14, 8.4.16 - 8.4.17, 8.5.0 - 8.5.2
object(test)#1 (10) { ["json":"test":private]=> string(182) "{ "modifiedElement1" : "11", "modifiedElement2" : "22", "exchangeValue1" : "11", "exchangeValue2" : "333", "inputFolderPath" : "input/", "outputFolderPath" : "output/" }" ["config":"test":private]=> object(stdClass)#2 (6) { ["modifiedElement1"]=> string(2) "11" ["modifiedElement2"]=> string(2) "22" ["exchangeValue1"]=> string(2) "11" ["exchangeValue2"]=> string(3) "333" ["inputFolderPath"]=> string(6) "input/" ["outputFolderPath"]=> string(7) "output/" } ["xmlFiles":"test":private]=> array(0) { } ["modifiedElement":"test":private]=> string(2) "11" ["modifiedElement2":"test":private]=> string(2) "22" ["exchangeValue":"test":private]=> string(2) "11" ["exchangeValue2":"test":private]=> string(3) "333" ["inputFolderPath":"test":private]=> string(6) "input/" ["outputFolderPath":"test":private]=> string(7) "output/" ["outputFileName":"test":private]=> NULL }
Output for 8.4.15
/bin/php-8.4.15: /usr/lib/libm.so.6: version `GLIBC_2.38' not found (required by /bin/php-8.4.15) /bin/php-8.4.15: /usr/lib/libm.so.6: version `GLIBC_2.35' not found (required by /bin/php-8.4.15) /bin/php-8.4.15: /usr/lib/libc.so.6: version `GLIBC_2.34' not found (required by /bin/php-8.4.15) /bin/php-8.4.15: /usr/lib/libc.so.6: version `GLIBC_2.38' not found (required by /bin/php-8.4.15)
Process exited with code 1.

preferences:
141.94 ms | 408 KiB | 5 Q