working on js validation