function submitsignupform(){document.getElementById("email").value=remove_all_spaces(document.getElementById("email").value);var email=document.getElementById("email").value;var email_is_ok=isEmail(email);if (email_is_ok){document.getElementById("nname").value=remove_all_spaces(document.getElementById("nname").value);var nn=document.getElementById("nname").value;if(nn.length>25){alert("User ID is too long ... try a shorter one");document.getElementById("nname").focus();return;}else if(nn.length<6){alert("User ID is too short ... try a longer one");document.getElementById("nname").focus();return;}if(!isAlphaNumeric(nn)){alert("Your user ID should contain only letters, numbers, underscores and hyphens.");document.getElementById("nname").focus();return;}document.getElementById("pwd1").value=remove_all_spaces(document.getElementById("pwd1").value);document.getElementById("pwd2").value=remove_all_spaces(document.getElementById("pwd2").value);if (document.getElementById("pwd1").value != document.getElementById("pwd2").value){alert("Your password and repeated password are different (they need to be the same)");document.getElementById("pwd1").focus();return;}var pwd=document.getElementById("pwd1").value;if (pwd.length >25){alert("Password is too long ... try a shorter one");document.getElementById("pwd1").focus();return;}else if(pwd.length<6){alert("Password is too short ... try a longer one");document.getElementById("pwd1").focus();return;}if(!isAlphaNumeric(pwd)){alert("Your password should contain only letters, numbers, underscores and hyphens.");document.getElementById("pwd2").value='';document.getElementById("pwd1").value='';document.getElementById("pwd1").focus();return;}document.getElementById("ccode").value=remove_all_spaces(document.getElementById("ccode").value);var ccode = document.getElementById("ccode").value;if(ccode.length!=5){alert('The security code appears to be invalid. It should be 5 characters in length.');document.getElementById("ccode").focus();return;}if(!document.getElementById("tos").checked){alert('Please agree to the Terms of Service if you wish to create an account, by ensuring the checkbox is checked.');document.getElementById("tos").focus();return;}document.getElementById("signup").submit();}else{alert("An invalid e-mail address appears to have been entered");document.getElementById("email").focus();}}