cleaning input from javascript -ish