3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $Wales = 'Swansea'; extract($capitalcities, EXTR_SKIP); print $Wales; print $Scotland; extract($capitalcities, EXTR_PREFIX_SAME, "country"); print $Wales; print $country_England; extract($capitalcities, EXTR_PREFIX_ALL, "country"); ?>
based on gCXfU
Output for 5.3.0 - 7.2.0
Warning: extract() expects parameter 1 to be array, null given in /in/OFtBN on line 3 Swansea Notice: Undefined variable: Scotland in /in/OFtBN on line 5 Warning: extract() expects parameter 1 to be array, null given in /in/OFtBN on line 6 Swansea Notice: Undefined variable: country_England in /in/OFtBN on line 8 Warning: extract() expects parameter 1 to be array, null given in /in/OFtBN on line 9
Output for 5.2.7 - 5.2.17
Warning: extract(): First argument should be an array in /in/OFtBN on line 3 Swansea Notice: Undefined variable: Scotland in /in/OFtBN on line 5 Warning: extract(): First argument should be an array in /in/OFtBN on line 6 Swansea Notice: Undefined variable: country_England in /in/OFtBN on line 8 Warning: extract(): First argument should be an array in /in/OFtBN on line 9
Output for 5.0.4 - 5.2.6
Notice: Undefined variable: capitalcities in /in/OFtBN on line 3 Warning: extract(): First argument should be an array in /in/OFtBN on line 3 Swansea Notice: Undefined variable: Scotland in /in/OFtBN on line 5 Notice: Undefined variable: capitalcities in /in/OFtBN on line 6 Warning: extract(): First argument should be an array in /in/OFtBN on line 6 Swansea Notice: Undefined variable: country_England in /in/OFtBN on line 8 Notice: Undefined variable: capitalcities in /in/OFtBN on line 9 Warning: extract(): First argument should be an array in /in/OFtBN on line 9
Output for 4.3.2 - 5.0.3
Notice: Undefined variable: capitalcities in /in/OFtBN on line 3 Warning: extract(): First argument should be an array in /in/OFtBN on line 3 Swansea Notice: Undefined variable: Scotland in /in/OFtBN on line 5 Notice: Undefined variable: capitalcities in /in/OFtBN on line 6 Warning: extract(): First argument should be an array in /in/OFtBN on line 6 Swansea Notice: Undefined variable: country_England in /in/OFtBN on line 8 Notice: Undefined variable: capitalcities in /in/OFtBN on line 9 Warning: extract(): First argument should be an array in /in/OFtBN on line 9
Output for 4.3.0 - 4.3.1
Notice: Undefined variable: capitalcities in /in/OFtBN on line 3 Warning: extract() [http://www.php.net/function.extract]: First argument should be an array in /in/OFtBN on line 3 Swansea Notice: Undefined variable: Scotland in /in/OFtBN on line 5 Notice: Undefined variable: capitalcities in /in/OFtBN on line 6 Warning: extract() [http://www.php.net/function.extract]: First argument should be an array in /in/OFtBN on line 6 Swansea Notice: Undefined variable: country_England in /in/OFtBN on line 8 Notice: Undefined variable: capitalcities in /in/OFtBN on line 9 Warning: extract() [http://www.php.net/function.extract]: First argument should be an array in /in/OFtBN on line 9