Help for this page
while ($test =~ m!\[img\]([^\[]+)\[\/img\]!g) { print "$1 \n"; }
while ($test =~ m!\[img\]((?:[^\[]+|\[[^i]|\[i[^m]|\[im[^g]|...)+\[\/i +mg\]!g) { print "$1 \n"; }