提交 10678a3c 编写于 作者: R root

支付部分新用户密码部分

上级 b08553b9
......@@ -291,16 +291,20 @@
}
// password 是否长度大于6,并且两个密码一致
if($("#id_create_account").is(':checked')){
new_user_pass = $("#billing:customer_password").val();
new_user_pass_cm = $("#billing:billing:confirm_password").val();
new_user_pass = $(".customer_password").val();
new_user_pass_cm = $(".customer_confirm_password").val();
//alert(new_user_pass);
//alert(new_user_pass.length);
//alert(new_user_pass_cm);
if(new_user_pass.length < 6){
$("#billing:customer_password").after('<div style="" class="validation-advice">Password length must be greater than or equal to 6</div>');
$(".customer_password").after('<div style="" class="validation-advice">Password length must be greater than or equal to 6</div>');
i++;
}else if(new_user_pass.length < 6){
$("#billing:billing:confirm_password").after('<div style="" class="validation-advice">Password length must be greater than or equal to 6</div>');
}else if(new_user_pass_cm.length < 6){
$(".customer_confirm_password").after('<div style="" class="validation-advice">Password length must be greater than or equal to 6</div>');
i++;
}else if(new_user_pass != new_user_pass){
$("#billing:billing:confirm_password").after('<div style="" class="validation-advice">The passwords are inconsistent</div>');
}else if(new_user_pass != new_user_pass_cm){
$(".customer_confirm_password").after('<div style="" class="validation-advice">The passwords are inconsistent</div>');
i++;
}
}
......
......@@ -98,11 +98,11 @@
<li style="display: none;" id="onestepcheckout-li-password">
<div class="input-box input-password">
<label for="billing:customer_password">Password</label><br>
<input name="billing[customer_password]" id="billing:customer_password" title="Password" value="" class="validate-password input-text" type="password">
<input name="billing[customer_password]" id="billing:customer_password" title="Password" value="" class="validate-password input-text customer_password" type="password">
</div>
<div class="input-box input-password">
<label for="billing:confirm_password">Confirm password</label><br>
<input name="billing[confirm_password]" title="Confirm Password" id="billing:confirm_password" value="" class="validate-password input-text" type="password">
<input name="billing[confirm_password]" title="Confirm Password" id="billing:confirm_password" value="" class="validate-password input-text customer_confirm_password" type="password">
</div>
</li>
<?php } ?>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册