$http_regular_request = array();
foreach ($http_regular_types as $regular_key) {
    if (isset($_GET[$regular_key])) {
        $http_regular_request["type"] = $regular_key;
        $http_regular_request["id"] = $_GET[$regular_key];
    }
}
//superprint($http_regular_request);
if (count($http_regular_request) == 0) {
    $http_regular_request["type"] = "site";
    $http_regular_request["id"] = "site";
    $content_pack = loadDefaultSite($content_pack);
} else {
    switch ($http_regular_request["type"]) {
        case "process":
            //superprint("load process");
            $content_pack = loadRequestPage("process", $http_regular_request["id"], $content_pack);
            break;
        case "page":
            $content_pack = loadRequestPage("page", $http_regular_request["id"], $content_pack);
            break;
        case "section":
            $content_pack = loadRequestSection($http_regular_request["id"], $content_pack);
            break;
        case "site":
            $content_pack = loadDefaultSite($content_pack);
            break;
        default:
            break;
    }
}
function loadRequestSection($section_id, $content_pack)
{
    $content_section = getBlendObjectFromID($section_id, "section");
    if ($content_section->type != "section") {
        $content_pack = loadDefaultSite($content_pack, 0);
        $content_pack["page"] = $content_section;
        return $content_pack;
    }
    if (isset($content_section->parent) and is_file($content_section->parent)) {
        $content_pack = loadSection_up($content_section->parent, $content_pack);
        $content_pack[$content_section->id] = $content_section;
    }
    $default = $content_section->getDefault();
    if ($default->type == "section") {
        $content_pack = loadSection_close_loop($default->url, $content_pack);
        return $content_pack;
    } else {
        $page = $content_section->getContent($default->id);
        $content_pack["page"] = $page;
        return $content_pack;
    }
}