3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php var_dump( preg_split( '/(?:"[^"]+")|\s+/', '"this is a string" cat dog "cow"'));
Output for 4.3.0 - 7.1.10
array(6) { [0]=> string(0) "" [1]=> string(0) "" [2]=> string(3) "cat" [3]=> string(3) "dog" [4]=> string(0) "" [5]=> string(0) "" }