<?php include_once APP_PATH.'admin/template/header.php';?>

<section class="content">

<section class="topsection">
	
	<!-- Heading -->
	<h1><?php echo ucwords($page);?></h1>
	
	<div class="entry-content"><?php echo $tl["cmdesc"]["d5"];?></div>
	
	<!-- Submenu -->
	<nav>
		<ul>
			<li class="selected"><a href="index.php?p=shop&amp;sp=categories"><?php echo $tl["menu"]["m5"];?></a></li>
			<li><a href="index.php?p=shop&amp;sp=newshopcategory"><?php echo $tl["cmenu"]["c4"];?></a></li>
			<li><a href="index.php?p=shop&amp;sp=newshop"><?php echo $tl["shop"]["m4"];?></a></li>
		</ul>
	</nav>
		
</section>

<div class="content-border">
<form class="jak_form_cat" method="post" action="<?php echo $_SERVER['REQUEST_URI']; ?>">
<div class="jak_dont_move_out">
<?php if (isset($JAK_CAT) && is_array($JAK_CAT)) foreach($JAK_CAT as $v) { if ($v["catparent"] == '0') { ?>
<table class="jak_move_cat">
<tr class="content-title">
<td class="content-go">#</td>
<td colspan="1"><?php echo $tl["cat"]["c"];?><a href="index.php?p=shop&amp;sp=categories&amp;ssp=edit&amp;sssp=<?php echo $v["id"];?>"><?php echo $v["name"];?></a></td>
<td><img src="img/move.png" width="20" height="10" alt="move" class="jak_fire_move" /></td>
<td colspan="4" class="right"><?php echo $tl["cat"]["c1"];?><input type="text" name="corder[]" class="corder" value="<?php echo $v["catorder"];?>" size="2" maxlength="2" /></td>
</tr>
<tr>
<td class="content-go"><?php echo $v["id"];?><input type="hidden" name="real_cat_id[]" value="<?php echo $v["id"];?>" /></td>
<td><?php echo $tl["cat"]["c3"];?><?php if (isset($JAK_CAT) && is_array($JAK_CAT)) foreach($JAK_CAT as $z) { if ($z["catparent"] != '0' && $z["catparent"] == $v["id"]) { ?><a href="index.php?p=shop&amp;sp=categories&amp;ssp=edit&amp;sssp=<?php echo $z["id"];?>"><?php echo $z["name"];?></a>, <?php } } ?></td>
<td class="content-go"><a href="index.php?p=shop&amp;sp=shopsubcategories&amp;ssp=<?php echo $v["id"];?>"><img src="img/subcat.png" width="15" height="14" alt="subcat" /></a></td>
<td class="content-go"><a href="index.php?p=shop&amp;sp=newshop&amp;ssp=<?php echo $v["id"];?>"><img src="img/addpage.png" width="14" height="16" alt="page" /></a></td>
<td class="content-go"><a href="index.php?p=shop&amp;sp=categories&amp;ssp=edit&amp;sssp=<?php echo $v["id"];?>"><img src="img/edit.png" width="14" height="16" alt="edit" /></a></td>
<td class="content-go"><a href="index.php?p=shop&amp;sp=categories&amp;ssp=delete&amp;sssp=<?php echo $v["id"];?>"><img src="img/delete.png" width="14" height="16" alt="delete" onclick="if(!confirm('<?php echo $tl["cat"]["al"];?>'))return false;" /></a></td>
</tr>
</table>
<?php } } ?>
</div>
<?php if ($JAK_CAT) { ?>
<div class="content-save">
<button type="submit" name="save" class="button"><?php echo $tl["general"]["g20"];?></button>
</div>
<?php } ?>
</form>
</div>		
</section>
		
<?php include_once APP_PATH.'admin/template/footer.php';?>