Skip to content

Commit

Permalink
Fixed #27,Error bei internem Banner mit Umlaut/Leerzeichen im Dateinamen
Browse files Browse the repository at this point in the history
  • Loading branch information
BugBuster1701 committed Sep 7, 2018
1 parent 7f97582 commit fc72c9d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/Resources/contao/classes/BannerInternal.php
Expand Up @@ -109,13 +109,13 @@ public function generateImageData()
$rootDir = $container->getParameter('kernel.project_dir');
$FileSrc = $container
->get('contao.image.image_factory')
->create($rootDir.'/' . \System::urlEncode($objFile->path), [$arrImageSizenNew[0], $arrImageSizenNew[1], 'proportional'])
->create($rootDir.'/' . $objFile->path, [$arrImageSizenNew[0], $arrImageSizenNew[1], 'proportional'])
->getUrl($rootDir);

//alt $picture = \Picture::create(\System::urlEncode($objFile->path), array($arrImageSizenNew[0], $arrImageSizenNew[1], $arrNewSizeValues[2]))->getTemplateData();
$picture = $container
->get('contao.image.picture_factory')
->create($rootDir . '/' . \System::urlEncode($objFile->path), $arrImageSizenNew);
->create($rootDir . '/' . $objFile->path, $arrImageSizenNew);
$picture = array
(
'img' => $picture->getImg(TL_ROOT, TL_FILES_URL),
Expand Down
2 changes: 1 addition & 1 deletion src/Resources/contao/classes/DcaBanner.php
Expand Up @@ -176,7 +176,7 @@ protected function listBannerInternal($row)
$rootDir = $container->getParameter('kernel.project_dir');
$banner_image = $container
->get('contao.image.image_factory')
->create($rootDir.'/'.\System::urlEncode($objFile->path), [$intWidth, $intHeight, 'proportional'])
->create($rootDir.'/'.$objFile->path, [$intWidth, $intHeight, 'proportional'])
->getUrl($rootDir);
}
break;
Expand Down
2 changes: 1 addition & 1 deletion src/Resources/contao/config/config.php
Expand Up @@ -14,7 +14,7 @@
*/

define('BANNER_VERSION', '1.0');
define('BANNER_BUILD' , '4');
define('BANNER_BUILD' , '5');

/**
* -------------------------------------------------------------------------
Expand Down

0 comments on commit fc72c9d

Please sign in to comment.