<?php

if(login_control()) {
	
	if($user["user_authority"] == 2) {

		if(!permission('access', 'root')){
	        require admin_view("unauthorized");
	        exit();
	    }

	    $child = $db->from('child_panels')->orderby('panel_created', 'DESC')->all();

		$title = "Child Panel";
		$page_title = "Child Panel";

		require admin_view('child');

	}else{

		require controller("404");

	}

}else{

	require controller("404");
	
}