<?
session_start();
ob_start("ob_gzhandler");
include("./includes/config.php");
include("./lang/arabic.php");
include("./includes/function.php");
include("./includes/online.php");
include("./includes/easytemplate.php");
include("./includes/inquiry.php");
$PhpGroup_style['def_style'] = "designs/$style";
$stylepath= $PhpGroup_style['def_style'];
$tpl = new EasyTemplate;
$tpl->Temp = $PhpGroup_style['def_style'];
$tpl->Cache = "easycache";
echo $tpl->display("headerinclude.html");
//start qurey
//get the last new poem
$selectnewdivan = mysql_db_query("$dbName", "SELECT * FROM `divan`  WHERE `divan_group` = '1' ORDER BY `divan_id` DESC LIMIT 10 ") ;
while ($ndivan =  @mysql_fetch_assoc($selectnewdivan)){
$nd[] =   $ndivan  ;
}

@mysql_free_result($selectnewdivan);
 echo $tpl->display("header.html");
echo $tpl->display("bodyinclude.html");
//endheader

$username = $_COOKIE[traidusername];
$password = $_COOKIE[traiduserpassword];
if(($username)==('')){
$message = "لم تقم بتسجيل الدخول";
}else{
$username = $_COOKIE['traidusername'];
$delete = @mysql_db_query("$dbName", "DELETE FROM `online` WHERE `user_name` = '$username' ") ;
$logout = @setcookie('traidusername',$username,time()-36000);
@setcookie('traidlastvisit',$uservisite,time()-36000);
if ($logout){
$message ="
$lang[suclogout]
<br><b><a href='index.php'>$lang[back] </a></b>

";
}else{
$message ="

<p dir='ltr'>$lang[errlogout]
<br><b><a href='index.php'>$lang[back] </a></b>

</p>
";

}
}
echo $tpl->display("message.html");
traidntright();
echo $tpl->display("footer.html");


ob_end_flush();
?>