How can I split a string by a delimiter, but not if it is escaped? For example, I have a string:
1|2\\|2|3\\\\|4\\\\\\|4
The delimiter is <
Recently I devised a solution:
$array = preg_split('~ ((?
But the black magic solution is still three times faster.