added validate.js