#------------------------------------------------------------------------------- $NoTypesDB = TRUE; #------------------------------------------------------------------------------- $HostingOrders = DB_Select('HostingOrders', array('ID', 'Password')); #------------------------------------------------------------------------------- switch (ValueOf($HostingOrders)) { case 'error': return ERROR | @Trigger_Error(500); case 'exception': # No more... break; case 'array': #--------------------------------------------------------------------------- foreach ($HostingOrders as $HostingOrder) { #------------------------------------------------------------------------- $Password = Crypt_Encode($HostingOrder['Password']); if (Is_Error($Password)) { return ERROR | @Trigger_Error(500); } #------------------------------------------------------------------------- $IsUpdate = DB_Update('HostingOrders', array('Password' => $Password), array('ID' => $HostingOrder['ID'])); if (Is_Error($IsUpdate)) { return ERROR | @Trigger_Error(500); } } break; default: return ERROR | @Trigger_Error(101); } #------------------------------------------------------------------------------- return TRUE;
<?php #------------------------------------------------------------------------------- /** @author Великодный В.В. (Joonte Ltd.) */ /******************************************************************************/ /******************************************************************************/ $__args_list = array('Value'); /******************************************************************************/ eval(COMP_INIT); /******************************************************************************/ /******************************************************************************/ $Config = Config(); #----------------------------------------------------------------------------- if ($Value) { #----------------------------------------------------------------------------- $Value = Crypt_Encode($Value, $Config['EncryptionKey']); if (Is_Error($Value)) { return ERROR | @Trigger_Error(500); } #----------------------------------------------------------------------------- } #----------------------------------------------------------------------------- #------------------------------------------------------------------------------- return $Value; #-------------------------------------------------------------------------------
return ERROR | @Trigger_Error(101); } #------------------------------------------------------------------------------- $Registrators = DB_Select('Registrators', array('ID', 'Password')); #------------------------------------------------------------------------------- switch (ValueOf($Registrators)) { case 'error': return ERROR | @Trigger_Error(500); case 'exception': # No more... break; case 'array': #--------------------------------------------------------------------------- foreach ($Registrators as $Registrator) { #------------------------------------------------------------------------- $Password = Crypt_Encode($Registrator['Password']); if (Is_Error($Password)) { return ERROR | @Trigger_Error(500); } #------------------------------------------------------------------------- $IsUpdate = DB_Update('Registrators', array('Password' => $Password), array('ID' => $Registrator['ID'])); if (Is_Error($IsUpdate)) { return ERROR | @Trigger_Error(500); } } break; default: return ERROR | @Trigger_Error(101); } #------------------------------------------------------------------------------- return TRUE;
#------------------------------------------------------------------------------- /** @author Alex Keda, for www.host-food.ru */ /******************************************************************************/ /******************************************************************************/ $__args_list = array('SchemeID', 'Code'); /******************************************************************************/ eval(COMP_INIT); /******************************************************************************/ /******************************************************************************/ #------------------------------------------------------------------------------- $Config = Config(); $Settings = $Config['Other']['Eval']; #------------------------------------------------------------------------------- #------------------------------------------------------------------------------- $Eval = SPrintF("ShowWindow('/%sOrder',{%sSchemeID:%s});", $Code, $Code, $SchemeID); #------------------------------------------------------------------------------- $Protocol = @$_SERVER['SERVER_PORT'] != 80 ? 'https' : 'http'; #------------------------------------------------------------------------------- $Link = SPrintF('%s://%s/UserRegister?Eval=%s', $Protocol, HOST_ID, Crypt_Encode($Eval, $Settings['EvalKey'])); #------------------------------------------------------------------------------- #------------------------------------------------------------------------------- $Name = Comp_Load('Formats/String', '[link]', 10, $Link); if (Is_Error($Name)) { return ERROR | @Trigger_Error(500); } #------------------------------------------------------------------------------- #------------------------------------------------------------------------------- return $Name; #------------------------------------------------------------------------------- #-------------------------------------------------------------------------------