Forums / General / PDF generation - has anyone ever made it work?

PDF generation - has anyone ever made it work?

Author Message

zurgutt -

Monday 05 February 2007 6:02:52 pm

I have a 3.8.3 site with content in utf-8. Content is mainly in norwegian.

In generated PDF the accented norwegian chars are garbage.

This bug has been unfixed for nearly TWO YEARS: http://issues.ez.no/6574

I have tried the suggested fixes in comments of this bug, best I could do was to convert title and main content back to readable iso-8859-1 using patch by Valentin Doroschuk. No luck with footer and anyway this would not work for any other language which does have all its chars in iso-8859-1. Setting PDF output to utf-8 crashes it.

Additionally sometimes output is not generated depending on page content - it especially seems to not like tables, most pages with a table in content have blank pdf's.

Has anyone worked around these bugs successfully? If so I'd be very thankful for a patch or some kind of instructions.. I have tried to look at code but not knowing anything about pdf encoding it is far too complex to find problems for me..

Certified eZ developer looking for projects.
zurgutt at gg.ee

Kristof Coomans

Monday 05 February 2007 11:35:57 pm

I know it's a bit cumbersome, but maybe an extra step to ODF can be easier ( http://www.xml.com/pub/a/2006/01/11/from-microsoft-to-openoffice.html ).

independent eZ Publish developer and service provider | http://blog.coomanskristof.be | http://ezpedia.org

zurgutt -

Tuesday 06 February 2007 3:49:46 am

It crossed my mind actually. Export of ez to OpenOffice format supposedly works (never tried myself) and i know that OO can export pdf too, probably reliably. Has someone gone this path? Hints about setup would be helpful.

Certified eZ developer looking for projects.
zurgutt at gg.ee

J-A Eberhard

Tuesday 06 February 2007 7:51:33 am

Having the same problem with UTF-8 and pdf export.
As you did I tried the hack provided in the bug report but I had finally to get back to non-UTF-8 format for portal in need of PDF generation.
Hoping that the integration of an OOo convertion engine in eZ will solve it.

Open Source Solution Provider
Open-Net Ltd Switzerland
http://www.open-net.ch

eZ debug

Timing: Jan 18 2025 15:50:58
Script start
Timing: Jan 18 2025 15:50:58
Module start 'content'
Timing: Jan 18 2025 15:50:58
Module end 'content'
Timing: Jan 18 2025 15:50:59
Script end

Main resources:

Total runtime0.8389 sec
Peak memory usage4,096.0000 KB
Database Queries199

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0060 588.9688180.8203
Module start 'content' 0.00600.6988 769.7891602.3281
Module end 'content' 0.70470.1341 1,372.1172337.3750
Script end 0.8389  1,709.4922 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00370.4457210.0002
Check MTime0.00150.1785210.0001
Mysql Total
Database connection0.00110.131510.0011
Mysqli_queries0.763390.98861990.0038
Looping result0.00220.26321970.0000
Template Total0.809196.420.4045
Template load0.00220.256920.0011
Template processing0.806996.183920.4034
Template load and register function0.00010.011710.0001
states
state_id_array0.00180.218410.0018
state_identifier_array0.00110.127720.0005
Override
Cache load0.00180.2157210.0001
Sytem overhead
Fetch class attribute can translate value0.00120.139240.0003
Fetch class attribute name0.00090.107370.0001
XML
Image XML parsing0.00190.220640.0005
class_abstraction
Instantiating content class attribute0.00000.001680.0000
General
dbfile0.00250.3017390.0001
String conversion0.00000.000830.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
4content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
4content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
4content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 15
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs