var check_session;
function CheckForSession() 
{
	jQuery.ajax({
		type: "POST",
		url: "lib/php/scheck.php",
		cache: false,
		success: function(res)
		{
			if(res == "1") 
			{
				window.location = 'lib/php/login.php?logout';
			}
		}
	});
}

$(function() 
{
	check_session = setInterval(CheckForSession, 180000);
});
