
		function setRemember(){	
			document.getElementById("remember").value=(rememberFlag)?"1":"0";
									  //document.getElementById("remember_img").src="images/login/checkbox_"+((rememberFlag)?"on":"off")+".gif";
			rememberFlag=!rememberFlag;
		}

		function forgotPassword(){
			$("#login_status_0").hide();
			$("#login_status_1").show();
			$("#log_in").css("background","url(../images/after_login.png)");	
		}
		
		function showGreeting(name){

			$("#login_status_0").hide();
			$("#login_status_2").show();
			$("#log_in").css("background","url(../images/after_login.png)");	
			
			$("#login_username").show();
			$("#login_username_seperator").show()
			$("#login_username").html("שלום "+txt2);
			
			$("#login_status").html("יציאה");
			$("#login_status").attr("title","יציאה");
			$("#login_status").attr("href","http://www.galim.org.il/cgi-bin/galim/register/logoff.pl");
	
			$.ajax({url:"http://www.galim.org.il/cgi-bin/galim/ajaxScript/build_login_messages.pl?act=show_login_communities_box",cache:false,success: function(data2){
				if (data2){
					$("#greeting").html("<span>שלום "+name+" !</span><br />"+data2);		
				}
				else{
					//alert("else");
					$("#greeting").addClass("not_community");
					
					$("#greeting").html("<span>שלום "+name+" !</span><br />"+message);
					}
			}})
		
			
			$.ajax({url:"http://www.galim.org.il/cgi-bin/galim/ajaxScript/build_login_messages.pl",cache:false,success: function(data){
				if (data){
					$("#box_content_3").html(data);}
			}});
 
		}
		var domain = location.href;
		domain = domain.split("/")
		//alert(domain[3])
		//alert(document.domain+" : "+location.href)
		if(domain[2]==document.domain && domain[3]!="") ;
		else window.onload=init;
		
		function init(){
			var txt = $.cookie('Ticket'); 
			//alert("555-"+txt);
			if(document.getElementById("login_status_0").style.display!="none") 
			   document.getElementById("user").focus();
		}
		
		function showLogin(flag){
			
			if(flag) document.getElementById("user").focus();	
			else document.getElementById("login").style.display="none";
			
		}
		
	
		
		/////////////////End of Log In /////////////////
