<?php
include("access.php");
include("include/admin.class.php");
include("include/conf.class.php");
$userinfo=$cartCore->get_user_info($CARTUSERNAME);
$cartCore->get_headder_customer();
$cartCore->view_welcome_customer($userinfo['FULL_NAME'],$userinfo['IMAGE']);
$cartCore->view_customer_sidebar($userinfo['USER_ID'],$TOKEN_ID);
$cartCore->view_credit($COMPANY_ID,$bk);

		if(isset($_GET['ref_id']) && $_GET['success_code'])
		{
			$ITEM_ID=$cartCore->md5_base64_decode($_GET['ref_id']);
			$global_id=$cartCore->md5_base64_decode($_GET['comp']);
			$fetch_company_details=$cartCore->fetch_global_config_by_company_id($global_id);
			$success_code=$cartCore->md5_base64_decode($_GET['success_code']);
		}

?>
<link rel="stylesheet" href="css/font_awesome_animated.css">
<!-- iCheck -->
    <link href="../vendors/iCheck/skins/flat/green.css" rel="stylesheet">
 <!-- Switchery -->
    <link href="../vendors/switchery/dist/switchery.min.css" rel="stylesheet">
		<link rel="stylesheet" type="text/css" href="css/set1.css" />
    <script src="js/jquery2.1"></script>

               <!-- top navigation -->
        <div class="top_nav">
          <div class="nav_menu">
            <nav>
              <div class="nav toggle">
                <a id="menu_toggle"><i class="fa fa-bars"></i></a>
              </div>

              <ul class="nav navbar-nav navbar-right">
              
              <?php
			  $row=mysql_fetch_assoc(mysql_query("select * from cart_order_product where ORDER_ID='".$ITEM_ID."'"));
			  $bk=$cartCore->md5_base64_encode($row['PRODUCT_CATAGORY_ID']);
			  ?>
              
              <?=$cartCore->view_userprofile($userinfo['USER_ID'],$userinfo['FULL_NAME'],$userinfo['IMAGE'],$TOKEN_ID,$COMPANY_ID,$bk)?>

                <li role="presentation" class="dropdown">
                  <a href="javascript:;" class="dropdown-toggle info-number" data-toggle="dropdown" aria-expanded="false">
                    <i class="fa fa-envelope-o"></i>
                    <span class="badge bg-green"><?=$cartAdminMain->getMessageCount($userinfo['USERNAME'])?></span>
                  </a>
                  <ul id="menu1" class="dropdown-menu list-unstyled msg_list" role="menu">
                  <?=$cartAdminMain->getUserMessage($userinfo['USERNAME'])?>
                    <li>
                      <div class="text-center">
                        <a href="message.php?token_id=<?=$TOKEN_ID?>&pid=<?=$cartCore->md5_base64_encode($userinfo['USERNAME'])?>">
                          <strong>See All Alerts</strong>
                          <i class="fa fa-angle-right"></i>
                        </a>
                      </div>
                    </li>
                  </ul>
                </li>
              </ul>
            </nav>
          </div>
        </div>
        <!-- /top navigation -->

        <!-- page content -->
        <div class="right_col" role="main">

          <div class="">
            <div class="page-title">
              <div class="title_left">
                <h3>Order Success</h3>
              </div>
            </div>
            
            <div class="clearfix"></div>

            <div class="row">
              <div class="col-md-12 col-sm-12 col-xs-12">
                <div class="x_panel">
                  <div class="x_title">
                    <ul class="nav navbar-right panel_toolbox">
                      <li><a class="collapse-link"><i class="fa fa-chevron-up"></i></a></li>
                    </ul>
                    <div class="clearfix"></div>
                  </div>
                  <div class="x_content">

                    <div class="col-md-7 col-sm-7 col-xs-12">
                    <h1></h1>
                    <div class="x_panel ui-ribbon-container fixed_height_390">
                          <div class="ui-ribbon-wrapper">
                            <div class="ui-ribbon">
                               <i class="fa fa-bell-o faa-wrench animated"></i>
                            </div>
                          </div>
                          <div class="x_content">

                            <div style="text-align: center; margin-bottom: 17px">
                              <span class="chart" data-percent="100">
                                                  <span class="percent"></span>
                              </span>
                            </div>

                            <h3 class="name_title" align="center">You`re all set!</h3>
                            <p align="center">ORDER #: <?=$ITEM_ID?></p>

                            <div class="divider"></div>

                            <p align="center">Your payment is recieved and we will contact you soon.</p>
                            <h4 style="color:#099" align="center">Thanks for being awesome, we hope you enjoy your purchase.</h4>
							
                            <?php
							if($success_code=='email_error')
							{
								echo '<p align="center" style="color:#F00">Something went wrong while delivering confirmation mail to your email address, pls contact us ('.$fetch_company_details['COMPANY_TELEPHONE_01'].') as soon as possible .</p>';
							}
							?>
                          </div>
                        </div>
                      
                      
                    </div>

                    <div class="col-md-5 col-sm-5 col-xs-12" style="border:0px solid #e5e5e5;">
						
                 
                      <div class="">
                        <div class="product_price">
                          
                          <div class="image view view-first">
                            <img style="width: 100%; display: block;" src="<?=$fetch_company_details['COMPANY_LOGO']?>" alt="image" />
                          </div>
                          
                        
                       
                      <br />
                          <span class="price-tax"><?=$fetch_company_details['COMPANY_NAME']?></span> <br />
						  <?=$fetch_company_details['COMPANY_ADDRESS_01']?>, <?=$fetch_company_details['COMPANY_CITY']?>,<?=$fetch_company_details['COMPANY_CITY']?>, <?=$fetch_company_details['COMPANY_COUNTRY']?> - <?=$fetch_company_details['COMPANY_POST_CODE']?>
                          <br>
                           <i class="fa fa-phone"></i> <?=$fetch_company_details['COMPANY_TELEPHONE_01']?> | <i class="fa fa-mobile"></i> <?=$fetch_company_details['COMPANY_MOBILE']?>
                        </div>
                      </div> 

                    </div>
                  </div>
                </div>
              </div>
            </div>
          </div>
        </div>
        <!-- /page content -->

        <!-- footer content --><?=$cartCore->get_footer();?>
        <!-- /footer content -->
      </div>
    </div>

   <!-- jQuery -->
    <script src="../vendors/jquery/dist/jquery.min.js"></script>
    <!-- Bootstrap -->
    <script src="../vendors/bootstrap/dist/js/bootstrap.min.js"></script>
    <!-- FastClick -->
    <script src="../vendors/fastclick/lib/fastclick.js"></script>
    <!-- NProgress -->
    <script src="../vendors/nprogress/nprogress.js"></script>    
    <!-- Chart.js -->
    <script src="../vendors/Chart.js/dist/Chart.min.js"></script>
    <!-- jQuery Sparklines -->
    <script src="../vendors/jquery-sparkline/dist/jquery.sparkline.min.js"></script>
    <!-- easy-pie-chart -->
    <script src="../vendors/jquery.easy-pie-chart/dist/jquery.easypiechart.min.js"></script>
    <!-- bootstrap-progressbar -->
    <script src="../vendors/bootstrap-progressbar/bootstrap-progressbar.min.js"></script>

    <!-- Custom Theme Scripts -->
    <script src="../build/js/custom.min.js"></script>
  </body>
</html>