js needs better string manipulation