// JavaScript Document
									// script for handle comments
									function ShowComments(PageID) {
										divCommentsHolder = new Fx.Style("divComments"+PageID, 'height', {duration:500,onComplete: function() {
											if ($("divComments"+PageID).style.height == '1px') {
//												$("divComments"+PageID).style.display = 'none'
												$("divComments"+PageID).style.height = '0'
											} else {
												location.href = "#aFormComment"+PageID
											}
											reSizeDivider()
										}
										});
										divCommentsHolder.options.transition = Fx.Transitions.Quad.easeInOut;
										if (parseInt($("divComments"+PageID).style.height)==0) {
											$('divComments'+PageID).style.display = 'block'
											divCommentsHolder.start(1,$('divComments'+PageID).scrollHeight)
											$("OpenCloseComments"+PageID).style.color = "#D7D7D7"
										} else {
											divCommentsHolder.start($('divComments'+PageID).scrollHeight,1)
											$("OpenCloseComments"+PageID).style.color = "#FF7216"
										}
									}						
									
									function ValidateForm(PageID) {
										var txtName=document.getElementById("txtName"+PageID)
										if ((txtName.value==null)||(txtName.value=="")){
											alert("הזן בבקשה שם")
											txtName.focus()
										} else {
											var email=document.getElementById("txtEmail"+PageID)
											if ((email.value==null)||(email.value=="")){
												alert("רגע, ומה עם אימייל")
												email.focus()
											} else {
												if (echeck(email.value)==false){
													email.focus()
												} else {
													var Spam=document.getElementById("txtSpam"+PageID)
													if ((Spam.value==null)||(Spam.value=="")){
														alert("רגע, ומה איתי")
														Spam.focus()
													} else {
														if (Spam.value!="מטוס"){
															alert("זו לא בדיוק התשובה הנכונה")													
															Spam.focus()
														} else {
															document.getElementById("FormComment"+PageID).submit()							
														}
													}
												}
											}
										}
									}	
							
							
									function echeck(str) {
									
											var at="@"
											var dot="."
											var lat=str.indexOf(at)
											var lstr=str.length
											var ldot=str.indexOf(dot)
											if (str.indexOf(at)==-1){
											   alert("Invalid E-mail ID")
											   return false
											}
									
											if (str.indexOf(at)==-1 || str.indexOf(at)==0 || str.indexOf(at)==lstr){
											   alert("מייל לא תקין")
											   return false
											}
									
											if (str.indexOf(dot)==-1 || str.indexOf(dot)==0 || str.indexOf(dot)==lstr){
												alert("מייל לא תקין")
												return false
											}
									
											 if (str.indexOf(at,(lat+1))!=-1){
												alert("מייל לא תקין")
												return false
											 }
									
											 if (str.substring(lat-1,lat)==dot || str.substring(lat+1,lat+2)==dot){
												alert("מייל לא תקין")
												return false
											 }
									
											 if (str.indexOf(dot,(lat+2))==-1){
												alert("מייל לא תקין")
												return false
											 }
											
											 if (str.indexOf(" ")!=-1){
												alert("מייל לא תקין")
												return false
											 }
									
											 return true					
									}
