function validate_commentForm() {

	if (document.commentForm.postname.value == '' && currentUser.id == 0) {
		alert('Please enter your name')
		document.commentForm.postname.focus()
		}
	else
	if (document.commentForm.email.value == '' && currentUser.id == 0) {
		alert('Please enter your email address')
		document.commentForm.email.focus()
		}
	else
	if (document.commentForm.comment.value.length < 4){
		alert('Please enter your comment')
		document.commentForm.comment.focus()
		}
	else
	if (document.commentForm.comment.value.length > 1000){
		alert('Please ensure your comment is less than 1000 characters')
		document.commentForm.comment.focus()
		}
	else 
	if (document.commentForm.comment.value.indexOf("<") != -1){
		alert('Please do not use the "<" character')
		document.commentForm.comment.focus()
		}
	else
	if (document.commentForm.comment.value.indexOf(">") != -1){
		alert('Please do not use the ">" character')
		document.commentForm.comment.focus()
		}
	else
	if (document.commentForm.postname.value.indexOf("<") != -1){
		alert('Please do not use the "<" character')
		document.commentForm.postname.focus()
		}
	else
	if (document.commentForm.postname.value.indexOf(">") != -1){
		alert('Please do not use the ">" character')
		document.commentForm.postname.focus()
		}
	else
	 {
			if(navigator.appName == "Netscape")
			{
				serverData = document.getElementById("serverData");			
			}			

		document.commentForm.add_comment_button.value = "Adding comment...";
		document.commentForm.add_comment_button.disabled =true;
		//document.commentForm.submit()
		comment    = document.commentForm.comment.value.replace(/ /g, '+')
		comment    = comment.replace(/\n/g, "[[br]]");
		comment    = comment.replace( "&", "%26");
		//comment    = comment.replace(">", "[[gt]]");
		postname   = document.commentForm.postname.value.replace(/ /g, '+')
		email      = document.commentForm.email.value
		website    = document.commentForm.website.value
		TBL = document.commentForm.TBL.value
		PID = document.commentForm.PID.value
		serverData.innerHTML = '<IFRAME src=/include/actions/add_comment.asp?postname='+postname+'&comment='+comment+'&email='+email+'&website='+website+'&TBL='+TBL+'&PID='+PID+' width=443 height=150 frameborder=0 MARGINWIDTH=2 MARGINHEIGHT=2 NORESIZE=NORESIZE SCROLLING=NO></IFRAME>'
		document.commentForm.add_comment_button.value = "Comment Posted!";
		document.commentForm.add_comment_button.disabled =true;
    } 
    }

         

