$displayvars = array("sources" => $sources, "scheme_data" => $conf);
            $middle = load_view(__DIR__ . '/views/scheme.php', $displayvars);
        } else {
            $middle = _("Unknown Scheme");
        }
        break;
    default:
        if (isset($_POST['type'])) {
            $scheme = $_POST['scheme_name'];
            $type = $_POST['goto0'];
            $res = FreePBX::Superfecta()->addScheme($scheme, array('DID' => $_POST['DID'], 'CID_rules' => $_POST['CID_rules'], 'Curl_Timeout' => $_POST['Curl_Timeout'], 'processor' => $_POST['processor'], 'multifecta_timeout' => $_POST['multifecta_timeout'], 'Prefix_URL' => $_POST['Prefix_URL'], 'SPAM_Text' => $_POST['SPAM_Text'], 'SPAM_Text_Substitute' => $_POST['SPAM_Text_Substitute'], 'enable_interceptor' => $_POST['enable_interceptor'], 'SPAM_threshold' => $_POST['SPAM_threshold'], 'destination' => !empty($type) ? $_POST[$type . '0'] : ''));
        }
        $middle = load_view(__DIR__ . '/views/main.php', array("schemes" => FreePBX::Superfecta()->getAllSchemes()));
}
$currentScheme = !empty($_REQUEST['scheme']) ? $_REQUEST['scheme'] : '';
$allSchemes = FreePBX::Superfecta()->getAllSchemes();
//show_view(__DIR__."/views/header.php", array("schemes" => $scheme_list));
//echo $middle;
//show_view(__DIR__.'/views/footer.php',array());
?>
<div class="container-fluid">
	<div class="row">
		<div class="col-sm-9">
			<?php 
echo $middle;
?>
		</div>
		<div class="col-sm-3 hidden-xs bootnav">
			<div class="list-group">
				<a href="?display=superfecta&amp;action=add" class="list-group-item"><i class="fa fa-plus"></i> <?php 
echo _('Add Scheme');