代码如下: //JS代码 function checkname() { var Msg = document.getElementById(“d_username”); var chk = CheckN(); if (chk) { $.ajax({ url: ‘registerOK.aspx’, type: ‘POST’, data: { lb: “checkname”, username: $(“#username”).val() }, dataType: ‘html’, timeout: 1