Fixed browser-side validation js functionality