<?php

/**
 * WebEngine CMS
 * https://webenginecms.org/
 * 
 * @version 1.2.0
 * @author Lautaro Angelico <http://lautaroangelico.com/>
 * @copyright (c) 2013-2019 Lautaro Angelico, All Rights Reserved
 * 
 * Licensed under the MIT license
 * http://opensource.org/licenses/MIT
 */

if (!defined('access') or !access) die();
?>
<!DOCTYPE html>
<html lang="en">

<head>
	<meta charset="utf-8" />
	<!--[if lt IE 9]><script src="https://cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv.min.js"></script><![endif]-->
	<title><?php $handler->websiteTitle(); ?></title>
	<meta name="generator" content="WebEngine <?php echo __WEBENGINE_VERSION__; ?>" />
	<meta name="author" content="Lautaro Angelico" />
	<meta name="description" content="<?php config('website_meta_keywords'); ?>" />
	<meta name="keywords" content="<?php config('website_meta_keywords'); ?>" />
	<link rel="shortcut icon" href="<?php echo __PATH_TEMPLATE__; ?>favicon.ico" />
	<meta name="viewport" content="width=1240, maximum-scale=1">
	<link href="https://fonts.googleapis.com/css2?family=Philosopher:wght@400;700&amp;display=swap" rel="stylesheet">
	<link href="https://fonts.googleapis.com/css2?family=Open+Sans:wght@400;600;700&amp;display=swap" rel="stylesheet">
	<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
	<link href="<?php echo __PATH_TEMPLATE_CSS__; ?>style.css" rel="stylesheet">
	<link href="<?php echo __PATH_TEMPLATE_CSS__; ?>swiper.min.css" rel="stylesheet">
	<link href="<?php echo __PATH_TEMPLATE_CSS__; ?>slick.css" rel="stylesheet">
	<link href="<?php echo __PATH_TEMPLATE_CSS__; ?>slick-theme.css" rel="stylesheet">
	<link href="<?php echo __PATH_TEMPLATE_CSS__; ?>webengine.css" rel="stylesheet">
	<link href="<?php echo __PATH_TEMPLATE_CSS__; ?>profiles.css" rel="stylesheet">
	<link href="<?php echo __PATH_TEMPLATE_CSS__; ?>override.css?v=<?php echo time();?>" rel="stylesheet">
	<link href="<?php echo __PATH_TEMPLATE_CSS__; ?>explorahost.css" rel="stylesheet">
	<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.2/css/all.min.css" integrity="sha512-HK5fgLBL+xu6dm/Ii3z4xhlSUyZgTT9tuc/hSrtw6uzJOvgRr2a9jyxxT1ely+B+xFAmJKVSTbpM/CuL7qxO8w==" crossorigin="anonymous" referrerpolicy="no-referrer" />
	<script>
		var baseUrl = '<?php echo __BASE_URL__; ?>';
	</script>
</head>

<body>
	<div class="wrapper">
		<header class="header">

			<div class="topPanel">
				<div class="topPanel-wrapper flex-c">
					<div class="topPanel-left flex-c">
						<div class="logoMini bright"><a href="<?php echo __BASE_URL__; ?>"><img src="<?php echo __PATH_TEMPLATE_IMG__; ?>logo-mini-s20.png" alt="Logo" width="170px"></a></div>
						<?php templateBuildNavbar(); ?>
					</div>
					<div class="topPanel-right">
						<?php if (isLoggedIn()) { ?>
							<a href="<?php echo __BASE_URL__; ?>usercp/myaccount" class="sign-up"><?php echo lang('module_titles_txt_4'); ?></a>
							<a href="<?php echo __BASE_URL__; ?>logout" class="sign-in login"><?php echo lang('menu_txt_6'); ?></a>
						<?php } else { ?>
							<a href="<?php echo __BASE_URL__; ?>register" class="sign-up"><?php echo lang('menu_txt_3'); ?></a>
							<a href="#login-login" class="sign-in login open_modal"><?php echo lang('menu_txt_4'); ?></a>
						<?php } ?>
					</div>
				</div>
			</div>
			
			<div class="sparks">
				<div class="spark_1"></div>
				<div class="spark_2"></div>
				<div class="spark_3"></div>
				<div class="spark_4 spark-big"></div>
			</div>

			<div class="logo">
				<div class="col-md-8 hidden-xs hidden-sm" style="padding-left: 10px;margin-top: -80px;">
					<a href="<?php echo __BASE_URL__; ?>"><img src="<?php echo __PATH_TEMPLATE_IMG__; ?>logo.png" class="bright"></a>
				</div>

				<div class="col-lg-2 col-md-2 col-sm-6 tableBlock-server">
					<div class="online only">
						<table style="width: 280px;" class="simple">
							<tbody>
								<tr>
									<td style="padding: 0px; text-align: center;">
										<h1 style="font-family: open sans, sans-serif; text-shadow: 1px 1px black; font-size: 40px!important; margin-bottom: -7px; color: #ffd250; font-weight: bold; text-shadow: 0 0 30px #ffd250;">
											<?php echo number_format($srvInfo[3]); ?></h1>

										Players Online <br><br>
										<div onclick="window.location.href = '<?php echo __BASE_URL__; ?>register'" style="border-radius: 10px; cursor: pointer; border: 3px solid #6d6d6d; padding: 5px 45px; height: 45px; background: rgba(0, 0, 0, 0.3); box-shadow: 0px 0px 10px #111; margin: 0px; font-size: 22px; font-weight: bold; font-style: italic; color: #fbac3f;"><?php echo lang('menu_txt_3'); ?></div>

										<br>
										<div onclick="window.location.href = '<?php echo $config_tpl['link_discord'];?>'" style="border-radius: 10px; cursor: pointer; border: 3px solid #6d6d6d; padding: 5px 45px; height: 45px; background: rgba(0, 0, 0, 0.3); box-shadow: 0px 0px 10px #111; margin: 0px; font-size: 22px; font-weight: bold; font-style: italic; color: #fbac3f;">Discord</div>

									</td>
								</tr>
							</tbody>
						</table>
					</div>
				</div>

			</div>
		</header><!-- .header-->

		<main class="content">
			<div class="page-content">
				<div class="row">
					<?php if($_REQUEST['page']=='usercp'){ ?>
						<div class="col-xs-4">
							<?php include(__PATH_TEMPLATE_ROOT__ . 'inc/modules/sidebar_usercp.php'); ?>
						</div>
						<div class="col-xs-8 container-mod">
							<?php $handler->loadModule($_REQUEST['page'], $_REQUEST['subpage']); ?>
						</div>
					<?php }else if (in_array($_REQUEST['page'], $disabledSidebar)) { ?>
						<div class="col-xs-12">
							<?php $handler->loadModule($_REQUEST['page'], $_REQUEST['subpage']); ?>
						</div>
					<?php } else { ?>
						<div class="col-xs-4">
							<?php include(__PATH_TEMPLATE_ROOT__ . 'inc/modules/sidebar.php'); ?>
						</div>
						<div class="col-xs-8 container-mod">
							<?php $handler->loadModule($_REQUEST['page'], $_REQUEST['subpage']); ?>
						</div>
					<?php } ?>
				</div>
			</div>
			<!--page content-->
		</main><!-- .content -->

		

	</div><!-- .wrapper -->

	<?php include(__PATH_TEMPLATE_ROOT__ . 'inc/modules/footer.php'); ?>


					</td>

				</tr>
			</tbody>
		</table>
	</div>

	<!-- Login Modal -->
	<?php if (!isLoggedIn()) { ?>
		<div id="login-login" class="modal_div">
			<span class="modal_close"></span>
			<div class="modal-content">
				<h2><span><?php echo lang('module_titles_txt_2'); ?></span></h2>
				<form action="<?php echo __BASE_URL__ . 'login'; ?>" method="post">
					<div class="form-group">
						<span>Username</span>
						<input type="text" class="form-control" name="webengineLogin_user" id="login_input">
					</div>
					<div class="form-group">
						<span>Password</span>
						<input type="password" class="form-control" name="webengineLogin_pwd" id="password_input">
					</div>
					<div class="formButton">
						<button class="button buttonsub" name="webengineLogin_submit" type="submit" value="submit"><?php echo lang('login_txt_3'); ?></button>
					</div>
				</form>
			</div>
		</div>
		<div id="overlay"></div>
	<?php } ?>

	<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.2.4/jquery.min.js"></script>
	<script src="<?php echo __PATH_TEMPLATE_JS__; ?>webengine.js"></script>
	<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa" crossorigin="anonymous"></script>
	<script src="<?php echo __PATH_TEMPLATE_JS__; ?>global.js"></script>
	<script src="<?php echo __PATH_TEMPLATE_JS__; ?>swiper.min.js"></script>
	<script src="<?php echo __PATH_TEMPLATE_JS__; ?>main.js"></script>
	<script src="<?php echo __PATH_TEMPLATE_JS__; ?>events.js"></script>
	<script src="<?php echo __PATH_TEMPLATE_JS__; ?>slick.min.js"></script>
	<script>
		$('.center').slick({
			infinite: true,
			centerMode: true,
			centerPadding: '50px 30px',
			slidesToShow: 3,
			slidesToScroll: 3
		});
	</script>
	
	
	
</body>

</html>