ord for registration
    function validatePassword(password, action) {
          var pw = password //document.getElementById("signup_password").value;
          var msg_key = action + "_error";
          //check empty password field
          if(pw == "") {
             document.getElementById(msg_key).innerHTML = "Password cannot be empty";
             return false;
          }

         //minimum password length validation
          if(pw.length < 6) {
             document.getElementById(msg_key).innerH