{{include file='head.tpl' inline}}
<script type="text/javascript">
	var request_type = '{{$_GET.request_type}}';
</script>
</head>
<body>
	<h1>{{$lang.Pages}}</h1>

{{if count( $aPages ) > 0}}
	<form action="?p={{$_GET.p}}" method="post" id="pages-multiselect">
		<fieldset>
			<table class="list" id="pages">
				<thead>
					<tr>
						<th class="enabled">{{$lang.Select}}</th>
						<th class="id">{{$lang.Id}}</th>
						<th class="name">{{$lang.Name}}</th>
					</tr>
				</thead>
				<tbody>
					{{$iType = 0}}
					{{foreach from=$aPages item=aPage}}
						{{if $aPage.iType != $iType}}
							<tr class="type"><th colspan="3">{{$lang.Menu}}: {{$aMenuTypes[$aPage.iType]}}</th></tr>
							{{$iType = $aPage.iType}}
						{{/if}}
						<tr class="l{{$aPage.iDepth}}">
							<td class="enabled">{{if $aPage.iToSelection}}<input type="checkbox" name="aSelected[{{$aPage.iPage}}]" id="selected-{{$aPage.iPage}}" />{{/if}}</td>
							<td class="id"><label for="selected-{{$aPage.iPage}}">{{$aPage.iPage}}</label><a href="#" class="Show_levels"></a></td>
							<td class="name"><label for="selected-{{$aPage.iPage}}">{{$aPage.sName}}</label>{{if !empty($aPage.sFullName)}}<span class="hidden" style="display:none;">{{$aPage.sFullName}}</span>{{/if}}</td>
						</tr>
					{{/foreach}}
				</tbody>
			</table>

			<div class="save float"><div class="floatcontainer">
				<input type="submit" class="submit" name="sOption" value="{{$lang.Save}}" />
			</div></div>

		</fieldset>
	</form>
{{else}}
	<div class="msg" id="error">
		<img src="{{$config.dir_templates}}admin/images/ico/msg_error.png" class="imgv" alt="" /> {{$lang.Data_not_found}}
	</div>
{{/if}}
	<div id="footer"></div>
</body>
</html>