in reply to global issue with an RE, I think...

The /g modifier when used in conjunction with an if is a little unusual. Typically you would see things like 'if (s/x/y/g)' or 'if (/x/)'. The /g means to do a global match, and it will return an array of applicable matches, if given the opportunity.

Maybe you are intending to write something like this:
open(INPUT, "ml_test.html"); # Read in the entire file into a single string. my $text = join ('', <INPUT>); close(INPUT); while ($text =~ /\bclb_new>\b(.*?)\b<\/a>/g) { print $1; }