// This function is used to check if a certain text is numeric or not function IsNumeric(sText) { var ValidChars = "0123456789."; var IsNumber=true; var Char; for (i = 0; i127) { alert("Your email address contains invalid characters."); return false; } } for (i=0; i127) { alert("Your email domain name contains invalid characters."); return false; } } if (user.match(userPat)==null) { alert("Your email address does not seem to be valid - check your spelling, including wrong use of commas, or a full point . at the end of the address!!"); return false; } var IPArray=domain.match(ipDomainPat); if (IPArray!=null) { for (var i=1;i<=4;i++) { if (IPArray[i]>255) { alert("Destination IP address is invalid!"); return false; } } return true; } var atomPat=new RegExp("^" + atom + "$"); var domArr=domain.split("."); var len=domArr.length; for (i=0;i=0 && List1.options[0].value != "-1") { // Add the selected item of List1 in List2 Element = new Option(List1.options[List1.options.selectedIndex].text,List1.options[List1.options.selectedIndex].value, false, true); if (List2.options[0].value != "-1") { List2.add(Element,List1.options[List1.options.selectedIndex].value); //List2.add(Element,List1.length); } else { List2.remove(0); List2.add(Element,0); } // Remove the selected item of List1 List1.remove(List1.options.selectedIndex); Element = new Option("----------------------------------------------","-1"); if (List1.options.length == 0) { List1.add(Element,0); } } } function SwapLists(List1,List2) { if (List1.options.length>0 && List1.options[0].value != "-1") { // Add items of List1 in List2 List2.remove(0); for(i=0;i -1) { parts[d++] = whole.substring(p, q); parts.length = d; p = q + 1; q = whole.indexOf(link, p); } parts[d++] = whole.substring(p); parts.length = d; return(parts); } //*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-**-*-*-*-*-*-*-*-*-*-*-* function myJoin(parts, link) { if (parts.join) { return(parts.join(link)); } var whole = ""; var thisLink = ""; for(var d = 0; d < parts.length;d++) { if (parts[d] != "") { whole = whole + thisLink + parts[d]; thisLink = link; } } return(whole); } /*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-* * Membership Page *-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*/ function CheckMembershipFields(Mode) { with(document.form) { //Check Username if (Mode == 'AddUser') { if ( Trim(txtMemberUsername.value) == '' ) { alert("You must enter the username!!"); txtMemberUsername.focus(); return false; } } // Check Password if ( Trim(txtMemberPassword.value) == '' ) { alert("You must enter the password!!"); txtMemberPassword.focus(); return false; } // Compare Passwords if( Trim(txtMemberPassword.value) != Trim(txtConfirmPass.value) ) { alert("The Password you provided does not match the confimation."); txtConfirmPass.focus(); return false; } // Check First Name if ( Trim(txtFName.value) == '' ) { alert("You must enter the first name!!"); txtFName.focus(); return false; } // Check Last Name if ( Trim(txtLName.value) == '' ) { alert("You must enter the last name!!"); txtLName.focus(); return false; } // Check Email if (!checkEmail()) { return false; } // Check Last Name if ( Trim(txtAddress.value) == '' ) { alert("Please you must enter the address!"); txtAddress.focus(); return false; } // Check Country if (ddlCountry.options.selectedIndex == 0) { alert("Please you must specify the country!"); ddlCountry.focus(); return false; } // Check City if ( Trim(txtCity.value) == '' ) { alert("Please you must enter the city!"); txtCity.focus(); return false; } // Check Last Name if ( Trim(txtPhone1.value) == '' ) { alert("You must enter the phone!!"); txtPhone1.focus(); return false; } useraction.value = Mode; action = "../Home/manage_membership.php"; submit(); } } function login_alert(){ alert("You must login first"); } function confirm_order(){ alert("Are you sure ?"); } function Problem(){ alert("Please Contact Us"); }