<?php
if (!isset($sortorder)) $sortorder = NULL;
if (!isset($c_active)) $c_active = NULL;
if ($action == 'add' && !$c_active) $c_active = 1;
print "
<div class='container popup'>";
include('includes/form/alert.php');
print "
	<form action='".$_SERVER['SCRIPT_NAME']."?".$_SERVER['QUERY_STRING']."' method='post' enctype='multipart/form-data'>
		<input type='hidden' name='csrf_token' value='".htmlspecialchars(csrf_token())."'>
		<input type='hidden' name='update' value='1' />";

if (isset($update_parent) && $update_parent === true) print "<input type='hidden' id='update_parent' name='update_parent' value='1' />";

print "
		<ul class='tabs toggle'>
			<li class='current'>
				<a href='#' title='".LABEL_DATA."' data-id='data'><i class='material-icons md-24'>edit</i>".LABEL_DATA."</a>
			</li>
		</ul>
		
		<div class='quick-action'>";
if (isset($id) && $id) print "<span class='id'>#".$id."</span>";
print "
		</div><!-- /.quick-action -->
		
		<div class='form' data-id='data'>
			<div class='form-content'>";


include('includes/form/id.php');
include('includes/form/sortorder.php');

include('includes/form/language.php');

#include('includes/backend_modules/form/c_page.php');
include('includes/form/c_module.php');

include('includes/form/module_title.php');
include('includes/form/module_text.php');

include('includes/form/icon.php');
#include('form/class.php');
include('includes/form/level_module.php');

include('includes/form/error.php');
include('includes/form/c_active.php');

print "
				<div class='form-action'>
					<button type='submit' class='btn save' name='submit' title='".LABEL_SAVE."'><i class='material-icons md-24'>save_alt</i>".LABEL_SAVE."</button>
				</div><!-- /.form-action -->
				
			</div><!-- /.form-content -->
		</div><!-- /.form -->";
/*
include('includes/form/images.php');
include('includes/form/files.php');
include('includes/form/links.php');
*/
print "
	</form>
	
</div><!-- /.container -->";