Ignore:
Timestamp:
Dec 20, 2013, 10:28:35 PM (11 years ago)
Author:
chronos
Message:
  • Opraveno: Ukládání příloh v aktualitách.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Modules/News/NewsPage.php

    r607 r614  
    88  var $ShortTitle = 'Aktuality';
    99  var $ParentClass = 'PagePortal';
    10   var $UploadedFilesFolder = 'uploads/';
     10  var $UploadedFilesFolder;
    1111
    1212  function Show()
    1313  {
     14    $this->UploadedFilesFolder = $this->System->ModuleManager->Modules['News']->UploadedFilesFolder;
    1415    if(count($this->System->PathItems) > 1)
    1516    {
     
    382383
    383384    // Get news from database by selected categories
    384     $UploadedFilesFolder = 'uploads/';
    385385    $DbResult = $this->Database->query('SELECT *, UNIX_TIMESTAMP(`Date`) AS `UnixTime` FROM `News` LEFT JOIN `User` ON `User`.`Id`=`News`.`User` WHERE '.$Where.' ORDER BY News.Date DESC LIMIT 0,'.$NewsCount);
    386386    while($Row = $DbResult->fetch_assoc())
     
    393393        foreach($Enclosures as $Enclosure)
    394394        {
    395           if(file_exists($UploadedFilesFolder.$Enclosure))
     395          if(file_exists($this->UploadedFilesFolder.$Enclosure))
    396396            $EnclosuresText .= ' <a href="'.$this->System->Link('/aktuality/'.$UploadedFilesFolder.$Enclosure).'">'.$Enclosure.'</a>';
    397397        }
Note: See TracChangeset for help on using the changeset viewer.