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

Dompdf Version 0.8.5 Arabic RTL Not Showing Correctly #2197

Closed
moussahoussein opened this issue Jul 18, 2020 · 2 comments
Closed

Dompdf Version 0.8.5 Arabic RTL Not Showing Correctly #2197

moussahoussein opened this issue Jul 18, 2020 · 2 comments

Comments

@moussahoussein
Copy link

moussahoussein commented Jul 18, 2020

I'm currently using the latest version of dompdf 0.8.5 , trying to export arabic text to pdf file

<?php

$linktentinvoice='<html><head><style>*{ font-family: DejaVu Sans, sans-serif; }</style><head><p>مرحبا</p></html>';

require_once 'dompdf/autoload.inc.php';

use Dompdf\Dompdf;
// instantiate and use the dompdf class
$dompdf = new Dompdf();
$dompdf->loadHtml($linktentinvoice, 'UTF-8');

// (Optional) Setup the paper size and orientation
$dompdf->setPaper('A4', 'landscape');

// Render the HTML as PDF
$dompdf->render();

// Output the generated PDF to Browser
$dompdf->stream();

?>

The result is showing : ا ب ح ر م

However the result has to be: مرحبا

@bsweeney
Copy link
Member

Dompdf does not currently support the features required to correctly render Arabic script. Please see #712 for more information. We've started working on support (see #2107) but it's not yet ready for release.

@learn05
Copy link

learn05 commented Mar 31, 2022

find a solution here Click here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants