<title>Edit Kategori Konten</title>
<div id="pagetitle">EDIT KATEGORI KONTEN</div>
<div id="batascontent" class="clearfix">
	<form action="?m=kontenkat_update" method="post" enctype="multipart/form-data">
		<?php 
			$db = mysqli_query($koneksi, "SELECT * FROM cmas_kontenkat WHERE kontenkat_id='$_GET[id]'");
			$dt = mysqli_fetch_array($db );
		?>
		<input name="kontenkat_id" type="hidden" value="<?php echo $dt['kontenkat_id']; ?>"/> 
		
		<div id="wrapgsetting" class="clearfix">
			<div id="gsettingleft">
				<div id="gsettingtitles">GENERAL</div>
				<div id="gsetting" class="clearfix">
					<div id="gsettinglabel">Konten Kategori</div>
					<div id="gsettingedit">
						<input name="kontenkat_judul" type="text" value="<?php echo $dt['kontenkat_judul']; ?>" autocomplete="off" required>
					</div>
				</div>
			</div>
			<div id="gsettingrite">
				<div id="gsettingtitles">ATTRIBUTE</div>
				<div id="gsetting" class="clearfix">
					<div id="gsettinglabel">Status</div>
					<div id="gsettingedit">
						<select name="kontenkat_status" required>
							<option value="<?php echo $dt["kontenkat_status"]; ?>"><?php echo $dt["kontenkat_status"]; ?></option>
							<?php $stdb=mysqli_query($koneksi, "SELECT * FROM cmas_status ORDER BY status_id ASC"); while($stdt=mysqli_fetch_array($stdb)) { ?>
								<option value="<?php echo $stdt['status_nama']; ?>"><?php echo $stdt['status_nama']; ?></option>
							<?php } ?>
						</select>
					</div>
				</div>
			</div>
		</div>
		<div id="tombolsubmit">
			<a href="?m=kontenkat_index"><input name="button" type="button" value="KEMBALI" class="myButton"/></a>
			<input name="submit" type="submit" value="UPDATE" class="submitbutton"/>
		</div>
	</form>
	<div id="infobottom" class="clearfix">
		<div class="infobottomleft">
			Posted by <b><?php echo $dt['posted_nama']; ?></b> on <b><?php echo date_format(date_create($dt['postdated']), 'd/m/Y H:i:s'); ?></b>
		</div>
		<div class="infobottomrite">
			Updated by <b><?php echo $dt['updated_nama']; ?></b> on <b><?php echo date_format(date_create($dt['updated']), 'd/m/Y H:i:s'); ?></b>
		</div>
	</div>
</div>		