Updated regex and jsfiddle example