Location: PHPKode > scripts > PHP Hosting Directory > phphost_directoryv2/include/lost.php
<?

if ($_SERVER['REQUEST_METHOD'] == 'POST')
{
	$t->assign('result', 1);

	if ($vars['username'] != '')
	{
		$count =  mysql_result(mysql_query("SELECT COUNT(*) FROM `hsl_host` WHERE `username`='".$vars['username']."'"), 0, 0);
		$host = mysql_fetch_array(mysql_query("SELECT * FROM `hsl_host` WHERE `username`='".$vars['username']."'"));
	}
	elseif ($vars['email'] != '')
	{
		$count =  mysql_result(mysql_query("SELECT COUNT(*) FROM `hsl_host` WHERE `email`='".$vars['email']."'"), 0, 0);
		$host = mysql_fetch_array(mysql_query("SELECT * FROM `hsl_host` WHERE `email`='".$vars['email']."'"));
	}

	if ($count > 0)
	{
		send_email($host['email'], "letters/lost.txt", read_file("letters/lost_subj.txt"), $host);
		$t->assign('sent', 1);
	}
	else
	{
		$t->assign('error', 1);
	}
}

$t->assign('main_html', $request[0].'.html');

?>
Return current item: PHP Hosting Directory