Пример #1
0
     $recurringamount = $temppricelist[$regperiod]['renew'];
     if ($dnsmanagement) {
         $recurringamount += $domaindnsmanagementprice;
     }
     if ($emailforwarding) {
         $recurringamount += $domainemailforwardingprice;
     }
     if ($idprotection) {
         $recurringamount += $domainidprotectionprice;
     }
     if ($promoid) {
         $recurringamount -= recalcPromoAmount("D." . $domainparts[1], $userid, $id, $regperiod . "Years", $recurringamount, $promoid);
     }
 }
 if (!$olddonotrenew && $donotrenew) {
     disableAutoRenew($id);
 }
 $table = "tbldomains";
 $array = array("registrationdate" => toMySQLDate($regdate), "domain" => $domain, "firstpaymentamount" => $firstpaymentamount, "recurringamount" => $recurringamount, "paymentmethod" => $paymentmethod, "registrar" => $registrar, "registrationperiod" => $regperiod, "expirydate" => toMySQLDate($expirydate), "nextduedate" => toMySQLDate($nextduedate), "subscriptionid" => $subscriptionid, "promoid" => $promoid, "additionalnotes" => $additionalnotes, "status" => $status, "dnsmanagement" => $dnsmanagement, "emailforwarding" => $emailforwarding, "idprotection" => $idprotection, "donotrenew" => $donotrenew);
 if ($oldnextduedate != $nextduedate) {
     $array['nextinvoicedate'] = toMySQLDate($nextduedate);
 }
 $where = array("id" => $id);
 update_query($table, $array, $where);
 logActivity("Domain Modified - User ID: " . $userid . " - Domain ID: " . $id, $userid);
 if ($additionaldomainfield) {
     $domainparts = explode(".", $domain, 2);
     $tld = "." . $domainparts[1];
     $tempdomainfields = $additionaldomainfields[$tld];
     foreach ($tempdomainfields as $key => $value) {
         $key = $value['Name'];
Пример #2
0
                 $errors[] = $domain . " - " . $values['error'];
                 continue;
             }
         }
     }
 } else {
     if ($update == "autorenew") {
         $ca->addToBreadCrumb($currpage . "#", $whmcs->get_lang("domainautorenewstatus"));
         if ($save) {
             check_token();
             foreach ($domainids as $domainid) {
                 if ($whmcs->get_req_var("enable")) {
                     update_query("tbldomains", array("donotrenew" => ""), array("id" => $domainid, "userid" => $client->getID()));
                     continue;
                 }
                 disableAutoRenew($domainid);
             }
         }
     } else {
         if ($update == "reglock") {
             $ca->addToBreadCrumb($currpage . "#", $whmcs->get_lang("domainreglockstatus"));
             if ($save) {
                 check_token();
                 foreach ($domainids as $domainid) {
                     $data = get_query_vals("tbldomains", "domain,registrar", array("id" => $domainid, "userid" => $client->getID()));
                     $domain = $data['domain'];
                     $registrar = $data['registrar'];
                     $domainparts = explode(".", $domain, 2);
                     $params = array();
                     $params['domainid'] = $domainid;
                     $params['sld'] = $domainparts[0];