<?
error_reporting(E_ALL ^ (E_NOTICE | E_WARNING));
//***************************************************
// http://www.scriptindonesia.com
// Solusi Hemat Script Bisnis Online Anda
// Menerima Jasa Pembuatan Website & Template Website
//***************************************************
?>
<?
if (!isset($_SESSION)) {
session_start();
}

$page = isset($_GET['page']) ? $_GET['page'] : null;
if($page == "logout")
{
  $id_aw                    = $_SESSION[user_session];
//$_SESSION[user_session]   = "";
  $_SESSION[user_email]     = "";
  $_SESSION[user_password]  = "";
  $_SESSION[user_nama]      = "";
  $_SESSION[user_status]    = "";
  $_SESSION[user_blokir]    = "";
  $_SESSION[user_counter]   = "";
  $_SESSION[user_paket]     = "";
  $_SESSION[user_profit]    = "";
  $_SESSION[user_id]        = "";
  $_SESSION[user_sponsor]   = "";
  $_SESSION[user_adminrp]   = "";

  session_destroy();
  header("location:../$id_aw");
}


//Edit Script AW 20140121
//if (session_is_registered("user_session"))
//if (isset($_SESSION['user_session']))

  if (isset($_SESSION['user_email']))
  {
include "../configdb.php";
include "../masterclass.php";
$db = new db_mysql($server_name, $userdb, $passdb, $databasename,"");
include "../function.php";
include "template.php";
  }

else {
	if($asal > 0) {
                include "../?scrindo=login";
	} else {
                include "login.php";
	}
     }

?>