Slight javascript additions, but non-working (no regex yet)