Fix #57: Regular expressions not matching \n.

JavaScript regular expressions do not match DOT to \n.
There are no modifiers that change this.

This patch removes .* from all regular expressions and instead uses
replace() and substring() to get the leftover part of the string.