<title>Visitor Details</title>
<div id="pagetitle">VISITOR DETAILS</div>
<div id="batascontent" class="clearfix">
	<?php 
		$id = mysqli_real_escape_string($koneksi, $_GET['id']);
		$db = mysqli_query($koneksi, "SELECT * FROM cmas_visitor WHERE visitor_id='$id'");
		$dt = mysqli_fetch_array($db);
		
		mysqli_query($koneksi, "UPDATE cmas_visitor SET visitor_status='0' WHERE visitor_id='$id'");
	?>
	<div id="wrapgsetting" class="clearfix">
		<div id="gsetting" class="clearfix">
			<div id="gsettinglabel">IP Address</div>
			<div id="gsettinginput">
				<?php echo $dt['visitor_ip']; ?>
			</div>
		</div>
		<div id="gsetting" class="clearfix">
			<div id="gsettinglabel">Date</div>
			<div id="gsettinginput">
				<?php echo date_format(date_create($dt['visitor_date']), 'd/m/Y'); ?>
			</div>
		</div>
		<div id="gsetting" class="clearfix">
			<div id="gsettinglabel">Time</div>
			<div id="gsettinginput">
				<?php echo date_format(date_create($dt['visitor_date']), 'H:i:s'); ?>
			</div>
		</div>
		<div id="gsetting" class="clearfix">
			<div id="gsettinglabel">Hits</div>
			<div id="gsettinginput">
				<?php echo $dt['visitor_hits']; ?>
			</div>
		</div>
		<div id="gsetting" class="clearfix">
			<div id="gsettinglabel">Agent</div>
			<div id="gsettinginput">
				<?php echo $dt['visitor_agent']; ?>
			</div>
		</div>
	</div>	
	<div id="tombolsubmit">
		<a href="?m=visitor_index"><input name="Button" type="button" value="KEMBALI" class="myButton"/></a>
	</div>
</div>
