<?php include "../datacon.php"; ?>
<?php  include('session.php'); ?>
<?php
if (isset($_POST['test'])){
//$pnumber =$_SESSION['username'];
$phone=$username;


$query = @mysql_query("select * from club where   phonenumber= '$phone'  ")or die(mysql_error());
$count = mysql_num_rows($query);

if ($count > 0){ 
?>
<script>

window.location = "index.php";
</script>
<?php
}else{?>
<script>
alert('Join Club');
window.location = "join.php";
</script>
<?php
}
}
?>
<?php
if (isset($_POST['testss'])){
//$pnumber =$_SESSION['username'];
$phone=$username;


$query = @mysql_query("select * from club where   phonenumber= '$phone'  ")or die(mysql_error());
$count = mysql_num_rows($query);

if ($count > 0){ 
?>
<script>

window.location = "earning.php";
</script>
<?php
}else{?>
<script>
alert('Join Club');
window.location = "join.php";
</script>
<?php
}
}
?>
<?php
if (isset($_POST['tests'])){
//$pnumber =$_SESSION['username'];
$phone=$username;


$query = @mysql_query("select * from club where   phonenumber= '$phone'  ")or die(mysql_error());
$count = mysql_num_rows($query);

if ($count > 0){ 
?>
<script>

window.location = "trees.php";
</script>
<?php
}else{?>
<script>
alert('Join Club');
window.location = "join.php";
</script>
<?php
}
}
?>
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>WealthClub</title>
    <!-- Core CSS - Include with every page -->
	 <link rel="shortcut icon" type="image/png" href="../img/favicon.png" />
    <link href="assets/plugins/bootstrap/bootstrap.css" rel="stylesheet" />
    <link href="assets/font-awesome/css/font-awesome.css" rel="stylesheet" />
    <link href="assets/plugins/pace/pace-theme-big-counter.css" rel="stylesheet" />
    <link href="assets/css/style.css" rel="stylesheet" />
    <link href="assets/css/main-style.css" rel="stylesheet" />
    <!-- Page-Level CSS -->
    <link href="assets/plugins/morris/morris-0.4.3.min.css" rel="stylesheet" />
   </head>
   <style>
   .button {
    background-color:#04B173; 
    border: none;
    color: white;
    padding: 15px 32px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
}
</style>
  // <?php  include('session.php'); ?>
<body>
    <!--  wrapper -->
    <div id="wrapper">
        <!-- navbar top -->
        <nav class="navbar navbar-default navbar-fixed-top" role="navigation" id="navbar">
            <!-- navbar-header -->
            <div class="navbar-header">
                <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".sidebar-collapse">
                    <span class="sr-only">Toggle navigation</span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                </button>
                <a class="navbar-brand" href="index.php">
                    <img src="assets/img/logo.png" alt="" />
                </a>
            </div>
            <!-- end navbar-header -->
            <!-- navbar-top-links -->
            <ul class="nav navbar-top-links navbar-right">
                <!-- main dropdown -->
               

                             

                <li class="dropdown">
                    <a class="dropdown-toggle" data-toggle="dropdown" href="#">
                        <i class="fa fa-user fa-3x"></i>
                    </a>
                    <!-- dropdown user-->
                    <ul class="dropdown-menu dropdown-user">
                        <li><a href="userprofile.php"><i class="fa fa-user fa-fw"></i>User Profile</a>
                        </li>
                          <li class="divider"></li>
						<li><a href="passchange.php"><i class="fa fa-gear fa-fw"></i>Change Password</a>
                        </li>
                        <li class="divider"></li>
                        <li><a href="logout.php"><i class="fa fa-sign-out fa-fw"></i>Logout</a>
                        </li>
                    </ul>
                    <!-- end dropdown-user -->
                </li>
                <!-- end main dropdown -->
            </ul>
            <!-- end navbar-top-links -->

        </nav>
        <!-- end navbar top -->

        <!-- navbar side -->
        <nav class="navbar-default navbar-static-side" role="navigation">
            <!-- sidebar-collapse -->
            <div class="sidebar-collapse">
                <!-- side-menu -->
                <ul class="nav" id="side-menu">
                    <li>
                        <!-- user image section-->
                        <div class="user-section">
                                                        <div class="user-info">
							  <?php $query= mysql_query("select * from operators where Userid = '$session_id'")or die(mysql_error());
			         $row = mysql_fetch_array($query);			
			         ?>
                                <div><?php echo $row['fname']." ".$row['lname']." ".$row['sname'];  ?></div>
                                <div class="user-text-online">
                                    <span class="user-circle-online btn btn-success btn-circle "></span>&nbsp;Online
                                </div>
                            </div>
                        </div>
                        <!--end user image section-->
                    </li>
                    <li class="sidebar-search">
                        <!-- search section-->
                        <div class="input-group custom-search-form">
                            <input type="text" class="form-control" placeholder="Search...">
                            <span class="input-group-btn">
                                <button class="btn btn-default" type="button">
                                    <i class="fa fa-search"></i>
                                </button>
                            </span>
                        </div>
                        <!--end search section-->
                    </li>
                                     
                     <li>
                        <form action="" method="post">
                         <button name="test" type="submit" align="center" class="button">Join Club</button>
                        </form> 
                    </li>
                    <li>
                        <form action="" method="post">
                         <button name="tests" type="submit" align="center"  class="button">Downline</button>
                        </form> 
                    </li>
                    <li>
                        <form action="" method="post">
                         <button name="testss" type="submit" align="center" class="button">My Ewallet</button>
                        </form> 
                    </li>
                      <li>
                        <a href="tut.php"><i class="fa fa-edit fa-fw"></i>Tutorial</a>
                    </li> 
                   <li>
                        <a href="userprofile.php"><i class="fa fa-edit fa-fw"></i>My Profile</a>
                    </li> 
                    <li>
                        <a href="passchange.php"><i class="fa fa-edit fa-fw"></i>Change Password</a>
                    </li>       
                    <li>
                        <a href="logout.php"><i class="fa fa-edit fa-fw"></i>Logout</a>
                    </li> 
                                
                </ul>
                <!-- end side-menu -->
            </div>
            <!-- end sidebar-collapse -->
        </nav>
        <!-- end navbar side -->
        <!--  page-wrapper -->
        <div id="page-wrapper">

            <div class="row">
                <!-- Page Header -->
                <div class="col-lg-12">
                    <h4 class="page-header">Dashboard</h4>
                </div>
                <!--End Page Header -->
            </div>

            <div class="row">
                <!-- Welcome -->
                <div class="col-lg-12">
                    <div class="alert alert-info">
                        <i class="fa fa-folder-open"></i><b>&nbsp;Hello ! </b>Welcome <b><?php echo $row['fname']." ".$row['lname']." ".$row['sname'];  ?></b>
 <b></b>
                    </div>
                </div>
                <!--end  Welcome -->
            </div>

          
                </div>
            </div>


        </div>
        <!-- end page-wrapper -->

    </div>
    <!-- end wrapper -->

    <!-- Core Scripts - Include with every page -->
    <script src="assets/plugins/jquery-1.10.2.js"></script>
    <script src="assets/plugins/bootstrap/bootstrap.min.js"></script>
    <script src="assets/plugins/metisMenu/jquery.metisMenu.js"></script>
    <script src="assets/plugins/pace/pace.js"></script>
    <script src="assets/scripts/siminta.js"></script>
    <!-- Page-Level Plugin Scripts-->
    <script src="assets/plugins/morris/raphael-2.1.0.min.js"></script>
    <script src="assets/plugins/morris/morris.js"></script>
    <script src="assets/scripts/dashboard-demo.js"></script>

</body>

</html>
