Bug #76160 [Com]: Font not loaded if path holds semi collon
Edit report at https://bugs.php.net/bug.php?id=76160&edit=1
ID: 76160
Comment by: spam2 at rhsoft dot net
Reported by: deepdiver at owncloud dot com
Summary: Font not loaded if path holds semi collon
Status: Open
Type: Bug
Package: GD related
Operating System: Debian Linux
PHP Version: Irrelevant
Block user comment: N
Private report: N
New Comment:
don't get me wrong but using special chars in folder and filenames on webservers is in 2018
still dumb for the same reasons it was 1998 and that won't change in 2028 that much
Previous Comments:
------------------------------------------------------------------------
[2018-03-29 09:48:53] deepdiver at owncloud dot com
Description:
------------
As soon as a semi-collon is in the path the font can no longer be loaded.
Tested with php 5.6 as well as php 7.2
Test script:
---------------
<?php
$fontFile = __DIR__ . '/fonts/foo;bar/OpenSans-Regular.ttf';
$image = imagecreate(128, 128);
$textColor = imagecolorallocate($image, 0, 0, 0);
imagettftext($image, 18, 0, 0, 0, $textColor, $fontFile, 'lorem');
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=76160&edit=1
Thread (8 messages)