<?PHP
$string = "[test]aaaaa[/[test][test]bbbb[/test][test]cccc[/test][test]ddd[/test]";
echo $string . "<br>";
preg_match("/\[test\].*?(\[\/test\])/i", $string, $m);
print_r($m);
?>
how to get value aaaaa and bbbb in multiple from capture [test] and [/test] ?