} else { $promo_value = formatCurrency($promo_value); } if ($promo_type == "Free Setup") { $promo_value = $aInt->lang("promos", "freesetup"); } $promo_recurring = $promo_recurring ? $aInt->lang("status", "recurring") : $aInt->lang("status", "onetime"); if ($promo_type == "Price Override") { $promo_recurring = $aInt->lang("promos", "priceoverride"); } if ($promo_type == "Free Setup") { $promo_recurring = ""; } $promoarr[$promo_id] = $promo_code . " - " . $promo_value . " " . $promo_recurring; } $tbl = new WHMCS_Table(); $tbl->add($aInt->lang("fields", "ordernum"), $orderid . " - <a href=\"orders.php?action=view&id=" . $orderid . "\">" . $aInt->lang("orders", "vieworder") . "</a>"); $tbl->add($aInt->lang("fields", "regdate"), $frm->date("regdate", $regdate)); $tbl->add($aInt->lang("fields", "product"), $frm->hidden("oldpackageid", $packageid) . $frm->dropdown("packageid", $aInt->productDropDown($packageid), "", "submit()")); $tbl->add($aInt->lang("fields", "firstpaymentamount"), $frm->text("firstpaymentamount", $firstpaymentamount, "10")); $tbl->add($aInt->lang("fields", "server"), $frm->dropdown("server", $serversarr, $server, "submit()", "", true)); $tbl->add($aInt->lang("fields", "recurringamount"), $frm->text("amount", $amount, "10") . " " . $frm->checkbox("autorecalcrecurringprice", $aInt->lang("services", "autorecalc"), $autorecalcdefault ? true : false)); $tbl->add($producttype == "server" ? $aInt->lang("fields", "hostname") : $aInt->lang("fields", "domain"), $frm->text("domain", $domain, "40") . " <a href=\"http://" . $domain . "\" target=\"_blank\" style=\"color:#cc0000\">www</a> <a href=\"#\" onclick=\"\$('#frmWhois').submit();return false\">" . $aInt->lang("domains", "whois") . "</a> <a href=\"http://www.intodns.com/" . $domain . "\" target=\"_blank\" style=\"color:#006633\">intoDNS</a>"); $tbl->add($aInt->lang("fields", "nextduedate"), in_array($billingcycle, array("One Time", "Free Account")) ? "N/A" : $frm->hidden("oldnextduedate", $nextduedate) . $frm->date("nextduedate", $nextduedate)); $tbl->add($aInt->lang("fields", "dedicatedip"), $frm->text("dedicatedip", $dedicatedip, "25")); $tbl->add($aInt->lang("fields", "billingcycle"), $aInt->cyclesDropDown($billingcycle)); $tbl->add($aInt->lang("fields", "username"), $frm->text("username", $username, "20") . (function_exists($module . "_LoginLink") ? " " . ServerLoginLink($id) : "")); $tbl->add($aInt->lang("fields", "paymentmethod"), paymentMethodsSelection() . " <a href=\"clientsinvoices.php?userid=" . $userid . "&serviceid=" . $id . "\">" . $aInt->lang("invoices", "viewinvoices") . "</a>"); $tbl->add($aInt->lang("fields", "password"), $frm->text("password", $password, "20")); $tbl->add($aInt->lang("fields", "promocode"), $frm->dropdown("promoid", $promoarr, $promoid, "", "", true) . " (" . $aInt->lang("services", "noaffect") . ")"); $tbl->add($aInt->lang("fields", "status"), $aInt->productStatusDropDown($domainstatus, false, "domainstatus", "prodstatus") . ($domainstatus == "Suspended" ? " (" . $aInt->lang("services", "suspendreason") . ": " . (!$suspendreason ? $_LANG['suspendreasonoverdue'] : $suspendreason) . ")" : ""));
} else { if (file_exists(ROOTDIR . "/modules/security/" . $module . "/logo.jpg")) { echo "<img src=\"../modules/security/" . $module . "/logo.jpg\" />"; } else { if (file_exists(ROOTDIR . "/modules/security/" . $module . "/logo.png")) { echo "<img src=\"../modules/security/" . $module . "/logo.png\" />"; } else { echo "<h2>" . (isset($configarray['FriendlyName']['Value']) ? $configarray['FriendlyName']['Value'] : ucfirst($module)) . "</h2>"; } } } if ($configarray['Description']['Value']) { echo "<p>" . $configarray['Description']['Value'] . "</p>"; } echo "<div id=\"conf" . $module . "\" style=\"" . $showstyle . "\">"; $tbl = new WHMCS_Table(); $tbl->add("Enable for Clients", $frm->checkbox("mod[" . $module . "][clientenabled]", "Tick to Enable", $moduleconfigdata['clientenabled'], "1", "enable" . $module), 1); $tbl->add("Enable for Staff", $frm->checkbox("mod[" . $module . "][adminenabled]", "Tick to Enable", $moduleconfigdata['adminenabled'], "1", "enable" . $module), 1); foreach ($configarray as $key => $values) { if ($values['Type'] != "System") { if (!isset($values['FriendlyName'])) { $values['FriendlyName'] = $key; } $values['Name'] = "mod[" . $module . "][" . $key . "]"; $values['Value'] = htmlspecialchars($moduleconfigdata[$key]); $tbl->add($values['FriendlyName'], moduleConfigFieldOutput($values), 1); continue; } } echo $tbl->output(); echo "<p align=\"center\">" . $frm->submit($aInt->lang("global", "savechanges")) . "</p>";