A regular expression to find a poorly formed link (but not malformed)...
(php version...)
/<\s*[aA]\s+[hH][rR][eE][fF]\s*=\s*"/
the / symbol is the "start" delimiter
the < symbol
* = 0 or more whitespace characters (\s = space, tab, newline)
either a or A
+ = at least one whitespace character (\s = space, tab, newline)
either h or H
either r or R
either e or E
either f or F
* = 0 or more whitespace characters (\s = space, tab, newline)
= symbol
* = 0 or more whitespace characters (\s = space, tab, newline)
" symbol
the / symbol is the "end" delimiter