3v4l.org

run code in 300+ PHP versions simultaneously
<?php $options = "onclick=\"double_list_move(\$('{$selectableName}'), \$('{$selectedName}')); return false;\""; if (!isset($options['alt'])) { $path_pos = strrpos($source, '/'); $dot_pos = strrpos($source, '.'); $begin = $path_pos ? $path_pos + 1 : 0; $nb_str = ($dot_pos ? $dot_pos : strlen($source)) - $begin; $options['alt'] = ucfirst(substr($source, $begin, $nb_str)); } echo $options; ?>

preferences:
44.49 ms | 402 KiB | 5 Q