ECSHOP 如何验证注册email已存在呢?
1.打开根目录下的js/user.js
2.找到
function checkEmail(email)方法通过调用ajax验证
以下是验证的js方法
function checkEmail(email)
{
var submit_disabled = false;
if (email == '')
{
document.getElementById('email_notice').innerHTML = msg_email_blank;
submit_disabled = true;
}
else if (!Utils.isEmail(email))
{
document.getElementById('email_notice').innerHTML = msg_email_format;
submit_disabled = true;
}
if( submit_disabled )
{
document.forms['formUser'].elements['Submit'].disabled = 'disabled';
return false;
}
Ajax.call( 'user.php?act=check_email', 'email=' + email, check_email_callback , 'GET', 'TEXT', true, true );
}
建站咨询热线
18503087281