$name = $data['name']; $predefaddons[$preid] = $name; } $tbl = new WHMCS_Table(); $tbl->add($aInt->lang("fields", "product"), $frm->hidden("oldserviceid", $id) . $frm->dropdown("id", $servicesarr, $id), 1); $tbl->add($aInt->lang("fields", "regdate"), $frm->date("regdate", $regdate)); $tbl->add($aInt->lang("fields", "setupfee"), $frm->text("setupfee", $setupfee, "10")); $tbl->add($aInt->lang("addons", "predefinedaddon"), $frm->dropdown("addonid", $predefaddons, $addonid, "", "", true)); $tbl->add($aInt->lang("global", "recurring"), $frm->text("recurring", $recurring, "10") . ($aid == "add" ? " " . $frm->checkbox("defaultpricing", $aInt->lang("addons", "usedefault"), true) : "")); $tbl->add($aInt->lang("addons", "customname"), $frm->text("name", $customname, "40")); $tbl->add($aInt->lang("fields", "billingcycle"), $aInt->cyclesDropDown($billingcycle, "", "Free")); $tbl->add($aInt->lang("fields", "status"), $aInt->productStatusDropDown($status)); $tbl->add($aInt->lang("fields", "nextduedate"), $frm->date("nextduedate", $nextduedate)); $tbl->add($aInt->lang("fields", "paymentmethod"), paymentMethodsSelection()); $tbl->add($aInt->lang("addons", "taxaddon"), $frm->checkbox("tax", "", $tax)); $tbl->add($aInt->lang("fields", "adminnotes"), $frm->textarea("notes", $notes, "4", "100%"), 1); echo $tbl->output(); if ($aid == "add") { echo "<p align=\"center\"><input type=\"checkbox\" name=\"geninvoice\" id=\"geninvoice\" checked /> <label for=\"geninvoice\">" . $aInt->lang("addons", "geninvoice") . "</a></p>"; } echo "<p align=\"center\">" . $frm->submit($aInt->lang("global", "savechanges"), "btn btn-primary") . " " . $frm->button($aInt->lang("global", "cancel"), "window.location='?userid=" . $userid . "&id=" . $id . "'") . "</p>"; } else { $serversarr = $serversarr2 = array(); $result = select_query("tblservers", "", array("type" => $module), "name", "ASC"); while ($data = mysql_fetch_array($result)) { $serverid = $data['id']; $servername = $data['name']; $activeserver = $data['active']; $servermaxaccounts = $data['maxaccounts']; $disabled = $data['disabled']; if ($disabled) {