title: enabled button if password match
body: <p>here is my script</p>
  
  <pre><code>$("#reg_confirm_pass").blur(function(){
  var user_pass= $("#reg_pass").val();
  var user_pass2=$("#reg_confirm_pass").val();
  var enter = $("#enter").val();
  
          if(user_pass.length == 0){
              alert("please fill password first");
              enter.disabled = true;
          } else if (user_pass == user_pass2 ){
              enter.disabled = false;
          } else {
              enter.disabled = true;
              alert("Your password doesn't same");
          }
  
      });
  </code></pre>
  
  <p>this my html</p>
  
  <pre><code>Password : &lt;input  type="password" name="user[user_pass]" id="reg_pass"  required="required"&gt;
  Confirm password &lt;input type="password" name="user[user_confirm_pass]" id="reg_confirm_pass" required="required"&gt;
  &lt;button type="submit" id="enter" disabled="true" value="Register"&gt;Register&lt;/button&gt;
  </code></pre>
  
  <p>i am really new in Javascript and jQuery, and this is my first using jquery. i need to make a disabled button if the password doesn't match but, after i put the same password the button is still disabled. </p>