Accented character (à) at end of line

Phoca PDF - creating PDF documents in Joomla! CMS
gulp
Phoca Member
Phoca Member
Posts: 33
Joined: 09 Oct 2012, 12:45

Accented character (à) at end of line

Post by gulp »

Putting an "à" at the end of a line of an article seems to break the generating pdf that will result in a blank page.
It could be related to wrong charset and conversion.
http://stackoverflow.com/questions/4141 ... y-pdf-file
gulp
Phoca Member
Phoca Member
Posts: 33
Joined: 09 Oct 2012, 12:45

Re: Accented character (à) at end of line

Post by gulp »

I can't make the posted solution on stackoverflow, then I temporarly patched the plugin ("plugins/phocapdf/content/content.php") by adding this line before the "writeHTML()":

Code: Select all

		$documentOutput = str_replace(utf8_encode("à"),"à",$documentOutput);
		$pdf->writeHTML($documentOutput , true);
What could be the final solution ?
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Accented character (à) at end of line

Post by Jan »

Hi, do you use font, which includes this character? Try to change (for test only) the font if this will help :idea:

Jan
If you find Phoca extensions useful, please support the project
gulp
Phoca Member
Phoca Member
Posts: 33
Joined: 09 Oct 2012, 12:45

Re: Accented character (à) at end of line

Post by gulp »

Yes the font "helvetica" includes this character.
I know that "myriad" is the best solution for charset compatibility, how to add this font to the default list ?
What should be the correct name and "case" of the font ? (myriad, myriad pro, Myriad Pro, ...)
Sometime this is very confusing :wink:
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Accented character (à) at end of line

Post by Jan »

The the fonts - font packages need to be created for the PDF feature.

See the fonts here:
https://www.phoca.cz/download/category/34-phocapdf-fonts
Try to use dejavusans, freesans, freemono or freeserif, they should include the character

I even test the standard font and get no problem there :idea: see image:

Image
If you find Phoca extensions useful, please support the project
Post Reply