3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function get_last_dot_occurence ($url ) { $fullArray = explode('.', $url)); switch (count($fullArray)) { case 1: return $url; break; case 2: $newArray = array("string1" => $fullArray[0], "string2" => $fullArray[1]) return $newArray; break; default: return ""; break; } } get_last_dot_occurence("test.com");
Output for 5.3.0 - 5.4.26
Parse error: syntax error, unexpected ')' in /in/fYs6J on line 3
Process exited with code 255.