Changed all kludgy regex subs to $1,$2,...