
		function check_email(frm){

									var str = frm;
									var valid = false;
									var RE_symbol = /@/;
									var RE_strUsername = /\w/;
									var RE_strURL = /\./;
		
									// search string for @ symbol
									if ( str.search(RE_symbol) == -1 || str.search(RE_strURL) == -1 ) {
										valid = false;
									}
									else {
										valid = true;
        							}
		                            						
									return valid;
							}
							
							function checkForm(){
							
								var returnValue = false;
								var emailValid = true;
								
								if ( document.getElementById("txtEmail").value != "" )
								{
									emailValid = check_email(document.getElementById("txtEmail").value);
								}
								
								if (document.getElementById("txtPri").value == "" ){
									alert("Please fill in your Name.");
									document.getElementById("txtPri").focus();
								}
								else if (document.getElementById("txtEmail").value == "" )
								{
									alert("Please fill in an E-mail Address.");
									document.getElementById("txtEmail").focus();
								}
								else if ( emailValid == false ){
									alert("Please enter a valid email: <user>@<organization>.<domain>");
									document.getElementById("txtEmail").focus();
								}
								else if (document.getElementById("txtPh").value == "" )
								{
									alert("Please enter a Telephone Number.");
									document.getElementById("txtPh").focus();
								}
								
								else
								{
								    
									return true;
								}
								
								return false;
							}