Hi I need a preg_split regex that will split a string at substrings in square brackets.
preg_split
This example input:
$string = \'I have a string cont
I think this is what you are looking for:
$array = preg_split('/(\[.*?\])/', $string, null, PREG_SPLIT_DELIM_CAPTURE);