/* Decoded by unphp.net */ require_once('fiberhome.php'); $Fiber = new FiberHome(); if (isset($_POST['insert']) && !empty($_POST['insert'])) { if ($_POST['insert'] == 'yes') { if (!isset($_POST['nome']) || !isset($_POST['ftth']) || !isset($_POST['pon']) || !isset($_POST['vlan']) || !isset($_POST['dt'])) { if (empty($_POST['nome']) || empty($_POST['ftth']) || empty($_POST['pon']) || empty($_POST['vlan']) || empty($_POST['dt'])) { exit("ERRO"); } } else { $Fiber->ONU_Add($_POST['pon'], $_POST['ftth'], $_POST['nome'], 'MAC', $_POST['dt']); $configuracoes = array ("CVLAN" => $_POST['vlan'], "CCOS" => 0); $Fiber->ONU_LAN_VLAN_ADD($_POST['pon'], $_POST['ftth'], "NA-NA-NA-1", $configuracoes); } } } $protocolo; $host; $finalBase; function Host() { $host = $_SERVER['HTTP_HOST']; return $host; } function Protocolo() { if (strpos(strtolower($_SERVER['SERVER_PROTOCOL']), 'https') === false) { $protocolo = 'http://'; } else { $protocolo = 'https://'; } return $protocolo; } function base($request_url = '') { $finalBase = Protocolo() . Host(); return empty($request_url) ? $finalBase . '/' : $finalBase . '/' . $request_url; }