// start table js
$(document).ready(function(){
//JQuery ready is quicker than onload
$(".stripeMe tr").mouseover(function() {$(this).addClass("over");}).mouseout(function() {$(this).removeClass("over");});
$(".stripeMe tr:even").addClass("alt");

$("a#autoSuggestionsList").click(function() { return false; });

/*
//login action
//when login form is submitted
// bind form using ajaxForm 


	$('#loginForm').ajaxForm({ 
        // target identifies the element(s) to update with the server response 
        target: '#loginError',        
        success: function(msg) { 
		//alert(msg);
		//if no message user logged in redirect		  
			$('#loginError').slideDown('slow');	        	
			
			// create a timer once finished hide loginerrors and clear timer
			var refreshId = setInterval(function()
   			{
			 	  $('#loginError').slideUp('slow');
				  if(msg == 'Login Success....Now logging you in')
				 {			
					document.location='./';				
				 }
				clearInterval(refreshId);
  			 }, 1000);    			
			
        } 
    }); 
	
	
//add contact
$('#responseBox').hide();//hide login errors

	$('#insertContact').ajaxForm({ 
        // target identifies the element(s) to update with the server response 
        target: '#responseBox',        
        success: function(msg) { 		
			    
			$('#responseBox').slideDown('slow');	        	
			
			// create a timer once finished hide loginerrors and clear timer
			var refreshId = setInterval(function()
   			{
			 	  $('#responseBox').slideUp('slow');
				  if(msg == '<p>Contact has been added to your contacts list.</p>')
				 {			
					document.location='contacts';				
				 }
				clearInterval(refreshId);
  			 }, 4000);   			
			
        } 
    }); 
	
	
	
//update contact
$('#responseBox').hide();//hide login errors

	$('#updateContact').ajaxForm({ 
        // target identifies the element(s) to update with the server response 
        target: '#responseBox',        
        success: function(msg) { 		
			    
			$('#responseBox').slideDown('slow');	        	
			
			// create a timer once finished hide loginerrors and clear timer
			var refreshId = setInterval(function()
   			{
			 	  $('#responseBox').slideUp('slow');
				  if(msg == '<p>Contact details have been updated.</p>')
				 {			
					document.location='contacts';				
				 }
				clearInterval(refreshId);
  			 }, 4000);   			
			
        } 
    }); 


//send mail
$('#responseBox').hide();//hide login errors


	$('#sendNewMail').ajaxForm({ 
        // target identifies the element(s) to update with the server response 
        target: '#responseBox',        
        success: function(msg) { 		
			   
			$('#responseBox').slideDown('slow');	        	
			
			// create a timer once finished hide loginerrors and clear timer
			var refreshId = setInterval(function()
   			{
			 	  $('#responseBox').slideUp('slow');
				  if(msg == '<p>Your email has been sent.</p>')
				 {			
					document.location='./';				
				 }
				clearInterval(refreshId);
  			 }, 4000);   			
			
        } 
    }); 
	
	
//reply to mail
$('#responseBox').hide();//hide login errors

	$('#replyMail').ajaxForm({ 
        // target identifies the element(s) to update with the server response 
        target: '#responseBox',        
        success: function(msg) { 		
			    
			$('#responseBox').slideDown('slow');	        	
			
			// create a timer once finished hide loginerrors and clear timer
			var refreshId = setInterval(function()
   			{
			 	  $('#responseBox').slideUp('slow');
				  if(msg == '<p>Your email has been sent.</p>')
				 {			
					document.location='./';				
				 }
				clearInterval(refreshId);
  			 }, 4000);   			
			
        } 
    }); 
	
//foward mail
$('#responseBox').hide();//hide login errors

	$('#fowardMail').ajaxForm({ 
        // target identifies the element(s) to update with the server response 
        target: '#responseBox',        
        success: function(msg) { 		
			    
			$('#responseBox').slideDown('slow');	        	
			
			// create a timer once finished hide loginerrors and clear timer
			var refreshId = setInterval(function()
   			{
			 	  $('#responseBox').slideUp('slow');
				  if(msg == '<p>Your email has been sent.</p>')
				 {			
					document.location='./';				
				 }
				clearInterval(refreshId);
  			 }, 4000);   			
			
        } 
    });

*/




});//close document ready
