<?PHP
	
	session_start();
	include_once("includes/includes.inc");

	$site = new Site();
	//$site->setKeywords();
?>

<!DOCTYPE html>
<head>
	<title>Lest We Forget</title>
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
	<link rel="stylesheet" type="text/css" href="<?=$site->getBasedir()?>css/index.css" media="all" />
	<link rel="stylesheet" type="text/css" href="<?=$site->getBasedir()?>css/dropzone.css" media="all" />
	
	<link rel="stylesheet" href="//code.jquery.com/ui/1.11.2/themes/smoothness/jquery-ui.css">
	<link rel="stylesheet" type="text/css" href="<?=$site->getBasedir()?>includes/CLEditor/jquery.cleditor.css" />
    

	<link href='https://fonts.googleapis.com/css?family=PT+Sans:400,700' rel='stylesheet' type='text/css'>
	<link rel="stylesheet" type="text/css" href="<?=$site->getBasedir()?>slick/slick.css"/>
	<link rel="stylesheet" type="text/css" href="<?=$site->getBasedir()?>slick/slick-theme.css"/>
</head>
<body> 
	<div id="main">
		<div id="head">
			<div id="logo">
				<a href="/"><img src="<?=$site->getBasedir()?>images/mapleleaf.png" style="float:left; height:80px; margin-top:5px;"></a>
			</div>
			<div style="float:left; font-family:Arial; width:230px; text-align:center;">
				<span style="font-size:30px;">Lest We Forget</span><br/>
				<span style="font-size:20px;">Bringing Them Home</span>
			</div>
			
			<div style="float:left; font-family:Arial; width:300px; text-align:center; padding-top:10px; margin-left:10%;">
				<span style="font-size:16px;">The photographic project of Canadian war graves in the Netherlands, Germany, Belgium and France</span><br/>
			</div>
			
			<div id="naarander" style="float:right; margin-left:5%;">
				<a href="http://www.stichtingopenboek.nl" target="_blank"><img src="<?=$site->getBasedir()?>/images/openboeklink.png" style="height:40px; margin-top:5px;"></a>
				<a href="http://www.cwgc.org" target="_blank"><img src="<?=$site->getBasedir()?>/images/commonwealth.png" style="height:40px;"></a>
			</div>
			
			<div style="float:right; width:30px; margin-top:20px;">
				<img src="<?=$site->getBasedir()?>images/zoek.png" style="height:30px; float:left; cursor:pointer; margin-top:30px;" onclick="location.href='https://staging.lestweforget1945.org/FotoOverzicht/Zoeken/'+$('#zoekveld').val().replace(new RegExp(' ','g'),'_')">							
			</div>
			<div style="float:right;">
				<p style="font-weight:600; font-size:15px;">Search</p>
				<input type="text" id="zoekveld" placeholder="Keywords" style="border:1px solid #0072bc; width:220px; height:20px;">
			</div>
			

			
		</div>
		
		<?
			if($site->getUrl(0) == "cms"){
				include("cms.php");
			} else if($site->getUrl(0) == "inloggen"){
				include("inloggen.php");
			} else {
			?>
		
			<div id="menubar">
				<div id="menu">
					<ul>
						<li>
							<a href="<?=$site->getBasedir()?>" style="color:#FFF;">Home</a>
						</li>
						<li>
							<a href="/Info/Information/">Information</a>
						</li>
						<?
							foreach($site->getCategorie() as $categorie){
								?>
								<li>
									<a href="<?=$site->getBasedir()?>FotoOverzicht/Categorie/<?=$categorie->get("id")?>/"><?=$categorie->get("titel")?></a>
									
								</li>
								<?
							}
						?>
						<li>
							<a href="/Info/Contact">Contact</a>
						</li>
						<li>
							<a href="/Info/Sponsors/">Sponsors / Donors</a>
						</li>
						<li>
							<a href="/Info/Nieuws/">News</a>
						</li>
						<li>
							<a href="/Info/Donations/">Donations</a>
						</li>
					</ul>
				</div>
			</div>
	
	
	
	<div id="content">
		<?
			if($site->getUrl(0) != ""){
				include($site->getUrl(0).".php");
				?>
				<div style="float:left; background-color: #FFF; width:100%;">
					&nbsp;
				</div>
				<?
			} else {
				/*
		?>
			<div>
				<div id="zoekbar" style="z-index: 2">
					<div id="zoekveldContainer">
						<div style="float:left; width:580px;">
							<p style="font-weight:600; font-size:15px;">Zoeken / Search / Suchen</p>
							<input type="text" id="zoekveld" placeholder="Zoekwoorden / Keywords / Stichworte" style="border:1px solid #0072bc; width:550px; height:20px; padding-left:20px;">
							<br/><a href="/skin/index.html"></a>
							<p style="font-size:15px;">Vul meerdere zoekwoorden in om de zoekresultaten te verfijnen</p>
						</div>
						<div style="float:left; width:30px; margin-top:20px;">
							<img src="<?=$site->getBasedir()?>images/zoek.png" style="height:30px; float:left; cursor:pointer; margin-top:30px;" onclick="location.href='FotoOverzicht/Zoeken/'+$('#zoekveld').val().replace(new RegExp(' ','g'),'_')">							
						</div>
					</div>
				</div>
				*/
				?>
				
				<div id="carousel" style="z-index: 1;">
					<?
						$numbers = range(1, 6);
						shuffle($numbers);
						foreach ($numbers as $number) {
						   ?>
						   <div class="one"><img src="<?=$site->getBasedir()?>/images/frontpage/frontpage<?=$number?>.jpg" style="width:100%;"></div>
						   <?
						}
					?>
				</div>
			</div>
				
		<?
			}		
		?>
	</div>
	<?
	}
	/*
	?>
	
	<div id="footer">
		<div style="<?=($site->getUrl(0) == "" ? "margin-top:-30px;" : "")?>">
		<a href="<?=$site->getBasedir()?>Info/Contact/">Contact</a> | <a href="<?=$site->getBasedir()?>Info/Oversjon/">Over Sjon.nl</a> | <a href="<?=$site->getBasedir()?>Info/Bestellen/">Bestellen</a> | <a href="<?=$site->getBasedir()?>Info/Redactie/">Redactie</a> | <a href="<?=$site->getBasedir()?>Info/Toepassen/">Toepassen</a> | <a href="<?=$site->getBasedir()?>Info/Portfolio/">Portfolio</a> | <a href="<?=$site->getBasedir()?>Info/Nieuws/">Nieuws</a>  | <a href="<?=$site->getBasedir()?>Info/Workshops/">Workshops</a> | <a href="<?=$site->getBasedir()?>Info/Socialmedia/">Social Media</a>
		</div>
	</div>	
	*/
	?>
	<script type="text/javascript" src="//code.jquery.com/jquery-1.11.0.min.js"></script>
	<script type="text/javascript" src="//code.jquery.com/jquery-migrate-1.2.1.min.js"></script>
	<script src="//code.jquery.com/ui/1.11.2/jquery-ui.js"></script>
	<script type="text/javascript" src="<?=$site->getBasedir()?>slick/slick.js"></script>
	<script src="<?=$site->getBasedir()?>javascript/cms.js"></script>
    <script src="<?=$site->getBasedir()?>javascript/dropzone.js"></script>
	<script type="text/javascript" src="<?=$site->getBasedir()?>includes/CLEditor/jquery.cleditor.min.js"></script>
	<link rel="stylesheet" href="<?=$site->getBasedir()?>css/jquery.fancybox.css?v=2.1.5" type="text/css" media="screen" />
	<script type="text/javascript" src="<?=$site->getBasedir()?>javascript/jquery.fancybox.js?v=2.1.5"></script>
	<link href='https://fonts.googleapis.com/css?family=PT+Sans:400,700' rel='stylesheet' type='text/css'>
	 <script src="<?=$site->getBasedir()?>javascript/jquery.unveil.js"></script>
    <script src="<?=$site->getBasedir()?>javascript/jQuery.js"></script>
</body>
</html>