Esempio n. 1
0
 if (Is_Error($Result)) {
     return $Link->GetError();
 }
 #-----------------------------------------------------------------------------
 $dDomainsOrders = MySQL::Result($Result);
 if (Is_Error($dDomainsOrders)) {
     return ERROR | @Trigger_Error(500);
 }
 #-----------------------------------------------------------------------------
 $DomainsOrders = new Tag('DomainsOrders');
 #-----------------------------------------------------------------------------
 foreach ($dDomainsOrders as $dDomainsOrder) {
     #---------------------------------------------------------------------------
     $Domain = $dDomainsOrder['domen'];
     #---------------------------------------------------------------------------
     $DomainOrder = new Tag('DomainOrder', new Tag('CreateDate', $dDomainsOrder['dateorder']), new Tag('ExpirationDate', (string) JulianDayToGregorian($dDomainsOrder['reg'])), new Tag('DomainName', SubStr($Domain, 0, $Index = StrRpos($Domain, '.'))));
     #---------------------------------------------------------------------------
     $Zone = SubStr($Domain, $Index);
     #---------------------------------------------------------------------------
     $Result = $Link->Query(SPrintF("SELECT * FROM `tarifdom` WHERE `name` = '%s'", $Zone));
     if (Is_Error($Result)) {
         return $Link->GetError();
     }
     #---------------------------------------------------------------------------
     $dDomainScheme = MySQL::Result($Result);
     if (Is_Error($dDomainScheme)) {
         return ERROR | @Trigger_Error(500);
     }
     #---------------------------------------------------------------------------
     $dDomainScheme = Current($dDomainScheme);
     #---------------------------------------------------------------------------
Esempio n. 2
0
 #-----------------------------------------------------------------------------
 foreach ($dDomainsOrders as $dDomainsOrder) {
     #---------------------------------------------------------------------------
     foreach (Array_Keys($dDomainsOrder) as $ColumnID) {
         #-------------------------------------------------------------------------
         $Column =& $dDomainsOrder[$ColumnID];
         #-------------------------------------------------------------------------
         $Column = Mb_Convert_Encoding($Column, 'UTF-8', $Charset);
     }
     #---------------------------------------------------------------------------
     $Domain = $dDomainsOrder['domen'];
     #---------------------------------------------------------------------------
     $DomainOrder = new Tag('DomainOrder');
     #---------------------------------------------------------------------------
     $DomainOrder->AddChild(new Tag('OrderDate', $dDomainsOrder['dateorder']));
     $DomainOrder->AddChild(new Tag('ExpirationDate', (string) JulianDayToGregorian($dDomainsOrder['reg'])));
     #---------------------------------------------------------------------------
     $Parse = WhoIs_Parse($Domain);
     #---------------------------------------------------------------------------
     switch (ValueOf($Parse)) {
         case 'error':
             return ERROR | @Trigger_Error(500);
         case 'false':
             #-----------------------------------------------------------------------
             $DomainName = SubStr($Domain, 0, $Index = StrRpos($Domain, '.'));
             $DomainZone = SubStr($Domain, $Index + 1);
             break;
         case 'array':
             #-----------------------------------------------------------------------
             $DomainName = $Parse['DomainName'];
             $DomainZone = $Parse['DomainZone'];