<?
	$login = $HTTP_COOKIE_VARS["metoo_cookielogin"];
	$password = $HTTP_COOKIE_VARS["metoo_cookiepassword"];

	$fn=Inc("userlist.csv");
	$fp = fopen ($fn, "r");
	if (filesize($fn)>0) { $userlist = fread($fp, filesize($fn)); }
	fclose($fp);
	Decrunch($userlist);
	$userlin=$lin;
	$usercell=$cell;

	$logged=false;
	if ($login != '') {
		$i=0;
		$found=false;
		do {
			$i++;
			if ($cell[$i][1]==$login) { $found=true; $user=$i; }
		} while ((!$found) && ($i<$lin));
		$returnpassword = $cell[$i][2];
		
		if (($found) && ($returnpassword == $password)) {
			$logged=true;
		}
	}
	if (!$logged) {
		echo "<center><font size=+1 color=red><b>".$loc[$loctag[2]+3][$lang]."</b></font><br><br>";
		echo "<a href='".IncL("login_metoo.php")."'>".$loc[$loctag[2]+4][$lang]."</a>";
		die();
	}
?>