3v4l.org

run code in 500+ PHP versions simultaneously
<?php $dst = 'a=b'; // $dst has no = leading or trailing or missing if (!in_array(strpos($dst, '='), [0, false, strlen($dst) - 1])) { print $dst; } if (str_contains($dst, '=') && !str_starts_with($dst, '=') && !str_ends_with($dst, '=')) { print $dst; }

preferences:
57.68 ms | 785 KiB | 5 Q