Ignore:
Timestamp:
Nov 5, 2012, 10:12:56 PM (12 years ago)
Author:
chronos
Message:
  • Opraveno: Odesílání emailů.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Common/Global.php

    r459 r460  
    133133    while($DbRow = $DbResult->fetch_assoc())
    134134    {     
    135       $Mail->AddTo($DbRow['To']);
     135      $Mail->AddToCombined($DbRow['To']);
    136136      $Mail->Subject = $DbRow['Subject'];
    137137      $Mail->From = $DbRow['From'];
    138138      $Mail->AddBody(strip_tags($DbRow['Content']), 'text/plain');
    139139      $Mail->AddBody($DbRow['Content'], 'text/html');
    140       if($DbRow['AttachmentFile'] != 'NULL')
     140      if($DbRow['AttachmentFile'] != '')
    141141      {
    142         $DbResult2 = $this->Dataase->select('File', '*', 'Id='.$DbRow['AttachmentFile']);
    143         $File = $DbResult2->fetch_assoc();
    144         $Mail->AttachFile($this->Config['Web']['FileRootFolder'].$File['DrivePath'], $File['MimeType']);
     142        $DbResult2 = $this->Database->select('File', '*', 'Id='.$DbRow['AttachmentFile']);
     143        while($File = $DbResult2->fetch_assoc())
     144          $Mail->AttachFile($this->Config['Web']['FileRootFolder'].$File['DrivePath'], $File['MimeType']);
    145145      }
    146146      $Mail->Send();
Note: See TracChangeset for help on using the changeset viewer.