Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix path to maps in AdobeFontMetrics.php #136

Merged
merged 1 commit into from
Jan 20, 2024
Merged

Conversation

danielscsc
Copy link
Contributor

@danielscsc danielscsc commented Jan 10, 2024

Currently get Fatal error: Uncaught Exception: Unknown encoding whenever passing an encoding to saveAdobeFontMetrics. This is because we aren't correctly pointing to the maps/ directory.

dirname(__FILE__) gives you php-font-lib/src/Fontlib dirname(__FILE__) . '/../' gives you php-font-lib/src/

We need one more level up, to hit /maps.

P.S. We can also use __DIR__ . '/../../' OR dirname(__DIR__) . '/../'

`dirname(__FILE__)` gives you `php-font-lib/src/Fontlib`
`dirname(__FILE__) . '/../'` gives you `php-font-lib/src/`

We need one more level up, to hit /maps.

P.S.  We can also use `__DIR__ . '/../../'` OR `dirname(__DIR__) . '/../'`
@bsweeney bsweeney added this to the 0.5.6 milestone Jan 10, 2024
@bsweeney bsweeney merged commit 34c5dc9 into dompdf:master Jan 20, 2024
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants