maxf5 Posted September 15, 2017 Share Posted September 15, 2017 Hi @Wanze, files are there on the ftp in /site/assets/files/{pageid} - also the thumbs are generated correctly. 2017-09-15 10:51:35 xxx_usr http://xxx.de/?pages2pdf=1048 IMagick Resized: captiva_sharkoon_0127-big.jpg => captiva_sharkoon_0127-big.220x220.jpg (220x220) 0.2990 secs 953844 => 14251 bytes (quality=90, sharpening=soft) 2017-09-15 10:51:35 xxx_usr http://xxx.de/?pages2pdf=1048 IMagick Resized: captiva_sharkoon_58-big.jpg => captiva_sharkoon_58-big.220x220.jpg (220x220) 0.2852 secs 814741 => 13240 bytes (quality=90, sharpening=soft) 2017-09-15 10:51:35 xxx_usr http://xxx.de/?pages2pdf=1048 IMagick Resized: captiva_sharkoon_0083-big.jpg => captiva_sharkoon_0083-big.220x220.jpg (220x220) 0.3268 secs 1532518 => 8103 bytes (quality=90, sharpening=soft) 2017-09-15 10:51:36 xxx_usr http://xxx.de/?pages2pdf=1048 IMagick Resized: captiva_sharkoon_0103-big.jpg => captiva_sharkoon_0103-big.220x220.jpg (220x220) 0.3187 secs 2139397 => 31538 bytes (quality=90, sharpening=soft) using ProcessWire 3.0.73, any known bugs here? Link to comment Share on other sites More sharing options...
ukyo Posted October 6, 2017 Share Posted October 6, 2017 I have Turkish, Russian language problem with your module, I tested also mPdf 6.1 from source directly and there is no problem with same test. I tested this example : https://github.com/mpdf/mpdf/blob/6.1/examples/example29_multilingual_autofont.php with all fonts. From source test : <?php $html = ' <style> body { font-family: sans; text-align: justify; } p { font-family: sans; } div { font-family: sans; } </style> <p>This document includes many languages. Selection of appropriate fonts is done automatically by using <b>AutoFont</b>. </p> <h3>Pangrams - (from Wikipedia) </h3> <p>The quick brown fox jumps over a lazy dog</p> <h4>Bulgarian</h4> <p>Жълтата дюля беше щастлива, че пухът, който цъфна, замръзна като гьон.</p> <p>За миг бях в чужд плюшен скърцащ фотьойл. </p> <h4>Catalan</h4> <p>Jove xef, porti whisky amb quinze glaçons d\'hidrogen, coi! </p> <p>Aqueix betzol, Jan, comprava whisky de figa </p> <h4>Czech</h4> <p>Příliš žluťoučký kůň úpěl ďábelské ódy </p> <h4>Danish</h4> <p>Høj bly gom vandt fræk sexquiz på wc </p> <h4>Dutch</h4> <p>Doch Bep, flink sexy qua vorm, zwijgt </p> <p>Pa\'s wijze lynx bezag vroom het fikse aquaduct </p> <h4>Finnish</h4> <p>Törkylempijä vongahdus </p> <h4>French</h4> <p>Portez ce vieux whisky au juge blond qui fume </p> <p>Bâchez la queue du wagon-taxi avec les pyjamas du fakir </p> <p>Voyez le brick géant que j\'examine près du wharf </p> <h4>German</h4> <p>Victor jagt zwölf Boxkämpfer quer über den großen Sylter Deich </p> <p>"Fix, Schwyz!" quäkt Jürgen blöd vom Paß </p> <p>"Falsches Üben von Xylophonmusik quält jeden größeren Zwerg"</p> <h4>Hungarian</h4> <p>Egy hűtlen vejét fülöncsípő, dühös mexikói úr Wesselényinél mázol Quitóban. </p> <h4>Icelandic</h4> <p>Kæmi ný öxi hér ykist þjófum nú bæði víl og ádrepa </p> <h4>Irish</h4> <p>D\'fhuascail Íosa Úrmhac na hÓighe Beannaithe pór Éava agus Ádhaimh </p> <p>D\'ḟuascail Íosa Úrṁac na hÓiġe Beannaiṫe pór Éaḃa agus Áḋaiṁ </p> <h4>Italian</h4> <p>"Quel fez sghembo copre davanti" </p> <p>"Ma la volpe col suo balzo ha raggiunto il quieto Fido" </p> <p>"Quel vituperabile xenofobo zelante assaggia il whisky ed esclama: alleluja!" </p> <h4>Lithuanian</h4> <p>Įlinkdama fechtuotojo špaga sublykčiojusi pragręžė apvalų arbūzą </p> <h4>Norwegian</h4> <p>Vår sære Zulu fra badeøya spilte jo whist og quickstep i min taxi. </p> <p>Høvdingens kjære squaw får litt pizza i Mexico by </p> <h4>Polish</h4> <p>Pójdźże, kiń tę chmurność w głąb flaszy! </p> <p>Pchnąć w tę łódź jeża lub ośm skrzyń fig. </p> <p>Mężny bądź, chroń pułk twój i sześć flag. </p> <h4>Portuguese</h4> <p>Blitz prende ex-vesgo com cheque fajuto. </p> <p>Gazeta publica hoje no jornal uma breve nota de faxina na quermesse. </p> <p>À noite, vovô Kowalsky vê o ímã cair no pé do pingüim queixoso e vovó põe açúcar no chá de tâmaras do jabuti feliz. </p> <p>Luís argüia à Júlia que «brações, fé, chá, óxido, pôr, zângão» eram palavras do português. </p> <h4>Romanian</h4> <p>Gheorghe, obezul, a reuşit să obţină jucându-se un flux în Quebec de o mie kilowaţioră. </p> <h4>Russian</h4> <p>В чащах юга жил бы цитрус? Да, но фальшивый экземпляр! </p> <p>(Using quasiobsolete spelling for last word to include ъ) В чащах юга жил бы цитрус? Да, но фальшивый экземпляръ! </p> <p>Эх, чужак! Общий съём цен шляп (юфть) — вдрызг! </p> <p>Экс-граф? Плюш изъят. Бьём чуждый цен хвощ! </p> <p>Съешь ещё этих мягких французских булок, да выпей же чаю. </p> <p>Широкая электрификация южных губерний даст мощный толчок подъёму сельского хозяйства. </p> <h4>Serbian</h4> <p>Љубазни фењерџија чађавог лица хоће да ми покаже штос. </p> <p>Ljubazni fenjerdžija čađavog lica hoće da mi pokaže štos. </p> <h4>Slovene</h4> <p>Šerif bo za vajo spet kuhal domače žgance </p> <p>Piškur molče grabi fižol z dna cezijeve hoste </p> <h4>Spanish</h4> <p>El veloz murciélago hindú comía feliz cardillo y kiwi. La cigüeña tocaba el saxofón detrás del palenque de paja. </p> <p>El pingüino Wenceslao hizo kilómetros bajo exhaustiva lluvia y frío, añoraba a su querido cachorro. </p> <p>Jovencillo emponzoñado de whisky: ¡qué figurota exhibe! </p> <p>Ese libro explica en su epígrafe las hazañas y aventuras de Don Quijote de la Mancha en Kuwait. </p> <p>Queda gazpacho, fibra, látex, jamón, kiwi y viñas. </p> <p>Whisky bueno: ¡excitad mi frágil pequeña vejez! </p> <h4>Swedish</h4> <p>Flygande bäckasiner söka hwila på mjuka tuvor. </p> <p>Yxskaftbud, ge vår wczonmö iqhjälp. </p> <h4>Ukrainian</h4> <p>Чуєш їх, доцю, га? Кумедна ж ти, прощайся без ґольфів! </p> <p>Жебракують філософи при ґанку церкви в Гадячі, ще й шатро їхнє п\'яне знаємо. </p> <h4>Turkish (pangram)</h4> <p>Pijamalı hasta yağız şoföre çabucak güvendi. </p> <h4>Greek</h4> <h5>Monotonic</h5> <p>Πάτερ ημών ο εν τοις ουρανοίς αγιασθήτω το όνομά σου· ελθέτω η βασιλεία σου· γενηθήτω το θέλημά σου, ως εν ουρανώ και επί της γης· τον άρτον ημών τον επιούσιον δος ημίν σήμερον· και άφες ημίν τα οφελήματα ημών, ως και ημείς αφίεμεν τοις οφειλέταις ημών· και μη εισενέγκης ημάς εις πειρασμόν, αλλά ρύσαι ημάς από του πονηρού. αμήν. </p> <h5>Polytonic</h5> <p>Πάτερ ἡμῶν ὁ ἐν τοῖς οὐρανοῖς ἁγιασθήτω τὸ ὄνομά σου· ἐλθέτω ἡ βασιλεία σου· γενηθήτω τὸ θέλημά σου, ὡς ἐν οὐρανῷ καὶ ἐπὶ τῆς γῆς· τὸν ἄρτον ἡμῶν τὸν ἐπιούσιον δὸς ἡμῖν σήμερον· καὶ ἄφες ἡμῖν τὰ ὀφελήματα ἡμῶν, ὡς καὶ ἡμεῖς ἀφίεμεν τοῖς ὀφειλέταις ἡμῶν· καὶ μὴ εἰσενέγκῃς ἡμᾶς εἰς πειρασμόν, ἀλλὰ ρῦσαι ἡμᾶς ἀπὸ τοῦ πονηροῦ. ἀμήν. </p> <h3>Languages</h3> <p>(The following are used for demonstration purposes only. Some of the following excerpts are taken from web pages from the BBC Foreign News just to show the script - I have no idea what they actually say!!)</p> <h4>Latvian</h4> <p>Latvijas institūts veic konsultatīvi koordinējošas funkcijas Latvijas starptautiskās atpazīstamības jomā; gatavo un izplata plašai sabiedrībai pieejamu, svarīgu pamatinformāciju saturošu, viegli izprotamu un iegaumējamu, kā arī pozitīvu iespaidu izraisošu vispārēju pamatinformāciju par Latviju, Latvijas dabu, sabiedrību, kultūru un vēsturi;</p> <h4>Azeri (az)</h4> <p>Qaz kəmərinin açılışında İran və Ermənistanın prezidentləri iştirak ediblər.</p> <p>İran qazını Ermənistana nəql edəcək bu kəmər Yerevan üçün xüsusi önəm daşıyır, belə ki, böyük etnik azərbaycanlı toplumuna malik İran təlatümlü regionda öz maraqlarını qorumaq üçün çox vaxt Ermənistanın müttəfiqi kimi görünüb.</p> <h4>Bulgarian</h4> <p>Последните донаборници в българската армия ще служат 9 месеца, както постановява закона 6 месеца е съкратеният срок само за завършилите висше образование - така министър Веселин Близнаков отхвърли различните интерпретации в публичното пространство по темата. Министърът на отбраната разформирова в Казанлък Втората ни рота от Ашраф и Втори пехотен взвод, завърнал се от миротворческа мисия от Баня Лука в Босна и Херцеговина.</p> <h4>Macedonian (mk)</h4> <p>Буш рече оти е суштински да се осигури безбедноста на Багдад и да се обнови нормалниот живот во остатокот од земјата.</p> <p>Митрева ја прозва владата за индолентен однос кон ова битката за зачувивање на уставното име на земјата.</p> <h4>Uzbek (uz)</h4> <p>Ироқликлар орасида тушкунлик ортиб бораяпти</p> <p>Ироқда ўтказилган сўнгги жамоатчилик фикрини ўрганиш натижаларига кўра, мамлакат келажаги борасида тушкун кайфиятда бўлган ироқликлар сони тобора ортиб бормоқда.</p> <h4>Kyrgyz (ky)</h4> <p>Казакстанда айыл тургундары уруша кетип 3 киши каза тапты Казакстандын Алматы шаарынын тушундагы айылда эки киши ортосундагы чатак чоң урушка айланып, ага элүү чакты киши аралашкан.</p> <h4>Albanian (sq)</h4> <p>Një anketë sugjeron se irakianët kanë një pesimizëm në rritje për të ardhmen e vendit të tyre.</p> <p>Presidenti shqiptar Alfred Moisiu dekretoi të hënën ndryshimet e propozuara nga kryeministri Sali Berisha në kabinetin e tij, pas zgjedhjeve lokale.</p> <h4>Vietnamese (vi)</h4> <p>Một khảo sát mới cho biết người dân Iraq ngày càng cảm thấy bi quan và không tin tưởng vào chính phủ cũng như liên quân</p> <p>Nga đang thực hiện chiến dịch cứu hộ sau khi có vụ nổ khí methane tại một mỏ than ở Siberia làm ít nhất 61 người thiệt mạng</p> <h4>Thai (pangram)</h4> <p>เป็นมนุษย์สุดประเสริฐเลิศคุณค่า กว่าบรรดาฝูงสัตว์เดรัจฉาน จงฝ่าฟันพัฒนาวิชาการ อย่าล้างผลาญฤๅเข่นฆ่าบีฑาใคร ไม่ถือโทษโกรธแช่งซัดฮึดฮัดด่า หัดอภัยเหมือนกีฬาอัชฌาสัย ปฏิบัติประพฤติกฎกำหนดใจ พูดจาให้จ๊ะๆ จ๋า น่าฟังเอยฯ </p> <!-- RTL LANGUAGES --> <div style="text-align: right;"> <h4>Hebrew (pangram)</h4> <p>דג סקרן שט בים מאוכזב ולפתע מצא חברה </p> <p>או הנסה אלהים, לבוא לקחת לו גוי מקרב גוי, במסת באתת ובמופתים ובמלחמה וביד חזקה ובזרוע נטויה, ובמוראים גדלים: ככל אשר-עשה לכם יהוה אלהיכם, במצרים--לעיניך </p> <h4>Arabic</h4> <p>قال الرئيس الامريكي جورج بوش في حديث متلفز في الذكرى الرابعة للغزو الامريكي للعراق ان الاولوية حاليا لاعادة الامن للعراق.</p> <p>هل ستسفر الجهود الدبلوماسية الجارية عن حلول؟ وكيف تنظر للاتهامات لبعض هذه الدول بالتدخل في الشأن العراقي، والتورط في دعم عمليات العنف؟ والى اي مدى يبدو الوضع في العراق انعكاسا للصراعات الإقليمية في المنطقة؟</p> <h4>Persian / Farsi</h4> <p>محمد البرادعی رئيس آژانس بين المللی انرژی اتمی پيشنهاد کرده است تهران برنامه جنجالی غنی سازی اورانيوم را متوقف کند و غرب نيز اجرای تحريم های تنبيهی مورد تائيد سازمان ملل متحد را به تعويق بياندازد.</p> <h4>Urdu</h4> <p>تمام انسان آزاد اور حقوق و عزت کے اعتبار سے برابر پیدا ہوۓ ہیں۔ انہیں ضمیر اور عقل ودیعت ہوئی ہی۔ اسلۓ انہیں ایک دوسرے کے ساتھ بھائی چارے کا سلوک کرنا چاہیۓ۔ </p> <h4>Pashto (ps)</h4> <p>په کابل او کندهار کې دوو ځانمرگو بريدونو لږ تر لږه يو ماشوم وژلى او اته تنه نور ىې ټپيان کړي. </p> <h4>Sindhi (sd)</h4> <p> واشنگٽن (م ڊ) آمريڪا چيو آهي ته ڪيري لوگربل تي پاڪ فوج جي تحفظات سان پاڪستان ۾ جمهوري طور آيل زرداري جي حڪومت کي ڪوبه خطرو ناهي، ان سوال تي تي ڪيري لوگربل ۾ پاڪستان کي غير مشروط امداد ڏيڻ جي ڳالهه ڪئي وئي آهي، جڏهن ته فوجي امداد تي شرط لاڳو ڪيا </p> </div> <!-- END RTL LANGUAGES --> <h3>Indic Scripts</h3> <h4> Malayalam </h4> <p>സംസ്ഥാനത്ത് രാഷ്ട്രീയ പുകമറ സൃഷ്ടിക്കാനാണ് വോട്ടര്‍പട്ടിക വിവാദത്തിലൂടെ കോണ്‍ഗ്രസ് ശ്രമിക്കുന്നതെന്ന് സിപി‌എം സംസ്ഥാന സെക്രട്ടറി പിണറായി വിജയന്‍ കുറ്റപ്പെടുത്തി। ഉദ്യോഗസ്ഥരെ ഭീഷണിപ്പെടുത്തി വരുതിയില്‍ നിര്‍ത്താനാണ് വയലാര്‍ രവി ഉള്‍പ്പെടെയുള്ളവര്‍ ശ്രമിക്കുന്നതെന്നും പിണറാ‍യി പ്രസ്താവനയില്‍ ആരോപിച്ചു। </p> <h4>Kannada</h4> <p> ತಮ್ಮದೇ ಕುಟುಂಬದ ಯುವತಿಯೊಬ್ಬಳನ್ನು ಸತತ ಹಲವಾರು ವರ್ಷ ಭೋಗಿಸಿದ ಭಾರತೀಯ ಮೂಲದ ಮೂವರು ದುರುಳ ಸಂಬಂಧಿಕರು ಅಪರಾಧಿಗಳೆಂದು ಸಾಬೀತಾಗಿದ್ದು, ಇಂಗ್ಲೆಂಡ್ ನ್ಯಾಯಾಲಯವು ದೀರ್ಘಾವಧಿ ಕಠಿಣ ಶಿಕ್ಷೆ ವಿಧಿಸಿದೆ. </p> <h4>Telegu</h4> <p>ఆగ్నేయ ఇరాన్‌లో ఆదివారం నాడు ఓ ఆత్మాహుతి దాడి జరగడంతో ఇరవై మంది మృతి చెందారు. <br /> ఆగ్నేయ ఇరాన్‌లో ఆత్మాహుతి దాడి జరగడంతో ఐదుగురు ఎలిట్ రెవల్యూషనరీ గార్డ్‌లతో సహా ప్రముఖ కమాండర్‌లతోసహా మొత్తం ఇరవై మంది మృతి చెందినట్లు ఇరాన్ లోక్‌సభ స్పీకర్ అలీ లారిజానీ తెలిపారు. </p> <h4>Tamil (ta)</h4> <p>இராக்கிய மக்கள் அவநம்பிக்கையுடன் இருப்பதாகவும், ஷியா மற்றும் சுனிக்கள் முரண்பட்ட கருத்துக்களுடன் துருவப்பட்ட நிலையில் இருப்பதாகவும் கருத்துக் கணிப்பு ஒன்று கூறுகிறது.</p> <h4>Oriya</h4> <p>ଓଡ଼ିଆ ଉଇକିପେଡିଆ ଆପଣଙ୍କୁ ସ୍ବାଗତ କରୁଛି। ଏହି ଉନ୍ମୁକ୍ତ ଜ୍ଞାନକୋଷଟି ଇଣ୍ଟରନେଟ ଉପରେ ଆଧାରିତ ଏବଂ ଏହା ବିଶ୍ବର ୫୦ଟି ଭାଷାରେ ଉପଲବ୍ଧ । ଏହାକୁ ଆପଣ ମଧ୍ୟ ବର୍ଦ୍ଧିତ ଓ ପରିବର୍ତିତ କରିପାରିବେ ଏବଂ ଏହାକୁ ଉନ୍ନତ କରିବା ପାଇଁ ନିଜର ଅବଦାନ ଦେଇ ପାରିବେ । ଆପଣଙ୍କ ପସନ୍ଦର ବିଷୟ ଗୁଡିକୁ ଆପଣ ନୂତନ ଭାବେରେ ଯୋଗ କରିପାରିବେ କିମ୍ବା ଏହି ପୃଷ୍ଠାକୁ ସମ୍ପାଦନ କରି ଏହା ସହିତ ଯୋଗ କରିପାରିବ । ସମସ୍ତ ପାଠ ଗୁଡିକ GNU ମୁକ୍ତ ଦଲିଲକରଣ ଲାଇସେନ୍ସର ସର୍ତ୍ତ ଅଧୀନରେ ଉପଲବ୍ଧ । ତଥାପି, ଆପଣ ଏହାକୁ ମୁକ୍ତ ଭାବେର ଇଲେକ୍ଟ୍ରୋନିକ୍ସ ପ୍ରିଣ୍ଟ୍ କିମ୍ବା ଅନ୍ୟାନ୍ୟ ପ୍ରିଣ୍ଟର ମାଧ୍ୟମରେ ବ୍ୟବହାର କରିପାରିବ । </p> <h4>Punjabi</h4> <p>ਕੇਂਦਰੀ ਗ੍ਰਹਿਮੰਤਰੀ ਪੀ.ਚਿਦੰਬਰਮ ਨੇ ਐਤਵਾਰ ਨੂੰ ਤਮਿਲਨਾਢੂ ਦੇ ਮੁੱਖਮੰਤਰੀ ਐਮ.ਕਰੁਣਾਨਿਧੀ ਨਾਲ ਮੁਲਾਕਾਤ ਕੀਤੀ।ਉਨ੍ਹਾ ਨੇ ਸ਼੍ਰੀਲੰਕਾ \'ਚ ਲਿੱਟੇ ਦੇ ਖਿਲਾਫ਼ ਯੁੱਧ ਦੌਰਾਨ ਉੱਝੜੇ ਹੋਏ ਲੱਗਭਗ ਢਾਈ ਲੱਖ ਤਮਿਲਾਂ ਦੀ ਮੁੜ ਰਿਹਾਇਸ਼ \'ਤੇ ਚਰਚਾ ਕੀਤੀ। </p> <h4>Gujarati (gu)</h4> <p> આ વાત હજાર વાર કહેવામાં આવી છે કે ફિલ્મ બનાવતી વખેત હંમેશા સૌથી વધુ ધ્યાન વાર્તા અને સ્ક્રીનપ્લે પર આપવુ જોઈએ. કારણ કે આ કોઈ પણ ફિલ્મની સફળતાનો મુખ્ય આધાર હોય છે. <br /> મોટા ફિલ્મ સ્ટાર્સ સાઈન કરવાથી, સ્ટંટ અને ગીતોથી પાણીની અંદર કે આકાશમાં કરોડો રૂપિયા ખર્ચ કરી ફિલ્માવેલા દ્રશ્યોથી કશુ જ નથી થતુ. પરંતુ આ બુનિયાદી વાત અત્યાર સુધી કોઈ લોકોને સમજાતી નથી. </p> <h4>Hindi (hi)</h4> <p>भारत और बरमूडा के बीच बारिश के कारण रुका मैच दोबारा शुरु हो गया है. भारत ने बरमूडा के सामने रिकॉर्ड 414 रनों का लक्ष्य रखा है. बरमूडा ने दो विकेट खो दिए हैं.</p> <h4>Nepali (ne) - Devanagari</h4> <p>अन्तरिम सरकारको गठनमा ढीलाइ हुनुका साथै आउंदो जेठ महिनाभित्र संविधानसभाको चुनाव होला कि नहोला भन्ने बहस चर्कीरहेको बेला चुनावकै विषयमा निर्वाचन आयोग र आठ दलको बेग्ला, बेग्लै भनाइ रहेको देखिएको छ।</p> <h4>Bengali (bn)</h4> <p> দক্ষিণ ওয়াজিরিস্থানে কর্মরত স্বেচ্ছাসেবী ও ত্রাণ সংস্থাগুলো ধারণা করছে সেনা অভিযানের তীব্রতা বাড়লে এই সংখ্যাটা আরও অনেক বেড়ে যাবে <br /> শরণার্থীদের স্রোত সামলাতে তারা ইতিমধ্যেই হিমশিম খাচ্ছেন, ফলে লড়াই থেকে পালিয়ে আসা বেসামরিক মানুষজনের সংখ্যা আরও বাড়লে স্বভাবতই সঙ্কট আরও জটিল হয়ে উঠবে </p> <h4>Assamese</h4> <p>অসমীয়া ৱিকিপিডিয়াৰ উদ্দেশ্য হ\'ল সম্পূৰ্ণ অসমীয়া ভাষাত এখনি বিশ্বকোষ প্ৰণয়ন কৰা। অন্য কোনো ভাষাৰ প্ৰবন্ধ এই বিশ্বকোষৰ বাবে গ্ৰহন কৰা নহ\'ব। বিশ্বকোষৰ অৱদানকাৰীসকললৈ সাদৰেৰে অনুৰোধ জনোৱা হ\'ল যাতে তেখেতসকলে অসমীয়া ভাষাৰ প্ৰচলিত বানান পদ্ধতি মানি চলে। বিদেশী শব্দৰ অসমীয়া প্ৰতিৰূপৰ ক্ষেত্ৰত যিহেতু অসমীয়া সাহিত্যিকসকল এতিয়াও ঐক্যমতত উপনীত হ\'ব পৰা নাই, ৱিকিপিডিয়াত বিদেশী শব্দৰ যিকোনো ধৰনৰ অসমীয়া ৰূপ গ্ৰাহ্য কৰা হ\'ব। </p> <h4>Japanese (pangrams)</h4> <h5>Iroha Uta SJIS</h5> <p>いろはにほへと ちりぬるを わかよたれそ つねならむ うゐのおくやま けふこえて あさきゆめみし ゑひもせす </p> <h5>Tori Naku Uta </h5> <p>とりなくこゑす ゆめさませ みよあけわたる ひんかしを そらいろはえて おきつへに ほふねむれゐぬ もやのうち </p> <h5>Ametsuchi No Uta </h5> <p>あめ つち ほし そら / やま かは みね たに / くも きり むろ こけ / ひと いぬ うへ すゑ / ゆわ さる おふ せよ / えのえ*を なれ ゐて </p> <h5>Taini no Uta </h5> <p>たゐにいて なつむわれをそ きみめすと あさりおひゆく やましろの うちゑへるこら もはほせよ えふねかけぬ </p> <h4>Chinese (simplified) GB2312 GB</h4> <p>来自商务部新闻办公室的消息称,中方免除与中国有外交关系的所有非洲重债穷国及最不发达国家截至2005年底对华到期政府无息贷款债务。有关部门已对相关债务进行全面清理核对,对与中国有外交关系的33个非洲重债穷国和最不发达国家,免除其截至2005年底168笔对华到期无息贷款债务。拟于2007年底前与受援国办理完免债协议。</p> <h4>Chinese (Traditional - Hong Kong) Big5</h4> <p>「憂鬱小王子」是一個教育網站,它成功結合了香港賽馬會防止自殺研究中心各方面的專才,為青少年人提供精神健康的訊息,對普及抑鬱症知識的貢獻良多。在香港,它曾獲選為「2004年十大健康網站」之一,該項選舉自2005年起改名現時的「優秀網站選舉」。其貢獻在國際間亦備受肯定,2005年,該網站榮獲第八屆「亞洲創新大獎」銀獎。</p> <h4>Korean UHC</h4> <p>키스의 고유조건은 입술끼리 만나야 하고 특별한 기술은 필요치 않다. </p> <h4>Mixed</h4> <p style="font-family: \'trebuchet ms\';">Distinguishes multiple languages enclosed in same element (tags): Arabic قال الرئيس English Cat sat on the large mat Tamil ஷியா Hindi भारत और Japanese いろはにほへと Chinese 来自商务部新闻办公 Thai เป็นมนุษย Viet Một khảo sát mới cho biết người dân Tamil ஷியா Chinese 来自商务部新闻办公 English Cat sat on the large mat </p> <h4>Unicode Plane 2</h4> <div> Unicode Plane 0 (BMP U+0000 - U+FFFF): 鼂 鼈 鼗 鼦 鼧 鼹 齄 齅 齐 齓 齚 齢 齩 齿 龎 龙 龟 龥 ------- Unicode Plane 2 (SIP characters > U+20000): 𠀡 𠀾 𠁆 𠁎 𠁨 𠂆 𠂇 𠂊 𠂔 𠃊 𠃋 𠃌 𠃍 𠃑 𠃮 𠄌 𠄎 𠄘 𠆤 𠆩 𠆫 𠇁 𠇔 𠇲 𠈄 𠈌 𠈔 𠈹 𠉛 𠉴 𠉵 𠊙 𠊞 𠊠 𠊷 𠊿 𠋀 𠋥 𠌊 ------- Unicode Plane 0 (BMPU+0000 - U+FFFF): 鼂 鼈 鼗 鼦 鼧 鼹 齄 齅 齐 齓 齚 齢 齩 齿 龎 龙 龟 龥 <br /> </div> '; require_once __DIR__ . '/mpdf/mpdf.php'; $mpdf = new mPDF(); $mpdf->autoScriptToLang = true; $mpdf->baseScript = 1; $mpdf->autoVietnamese = true; $mpdf->autoArabic = true; $mpdf->autoLangToFont = true; $mpdf->WriteHTML($html); $mpdf->Output(); exit; ?> Module test result : // Same $html used $pdf = $modules->get('WirePDF'); // Get mPDF instance $mpdf = $pdf->mpdf; $mpdf->autoScriptToLang = true; $mpdf->baseScript = 1; $mpdf->autoVietnamese = true; $mpdf->autoArabic = true; $mpdf->autoLangToFont = true; $mpdf->WriteHTML($html); $mpdf->Output(); Do you have any advise ? Link to comment Share on other sites More sharing options...
maxf5 Posted October 10, 2017 Share Posted October 10, 2017 Okay, my dev website was protected via htaccess. Therefore it couldn't render the images Link to comment Share on other sites More sharing options...
hellomoto Posted October 16, 2017 Share Posted October 16, 2017 On 9/3/2017 at 1:36 AM, hellomoto said: I have this $pdf = $modules->get('Pages2Pdf')->render(array( 'title' => 'PDF', 'markup' => '<a href=\'{url}\' target=\'_blank\'>{title}</a>', 'page_id' => '', )); $content .= <<<EOT <script type="text/javascript"> $("h1").append(" <small>[$pdf]</small>");</script> </script> EOT; which outputs to /?pdf={pid} but clicking the link just opens the current page in a new tab, no PDF. I have the template enabled in the module settings and the page is viewable. I would rather not have the ID in the download URL though. Currently I have the GET variable set to 'pdf', so it's ?pdf={id}. Since I'm linking from the page, can't it simply be ?pdf=1 for the pdf of the current page..? Thanks. Link to comment Share on other sites More sharing options...
pwFoo Posted November 7, 2017 Share Posted November 7, 2017 Hi, I want to generate a PDF with dynamic page breaks so that started paragraphs are pushed to the next page. Is that possible with pages2pdf or another php solution? If dynamic page breaks are not or not so easy to implement, a tool would be interesting, in which one could put the page breaks manually in a preview view before generating the PDF. Does anyone have an idea? Greetings Link to comment Share on other sites More sharing options...
bernhard Posted November 7, 2017 Share Posted November 7, 2017 Mpdf has a pagebreak method and you can also add CSS avoid-pagebreak to prevent two blocks from being split into multiple pages. I'm using [pagebreak] tags in ckeditor to give my clients the possibility of adding breaks 2 Link to comment Share on other sites More sharing options...
pwFoo Posted November 11, 2017 Share Posted November 11, 2017 Thanks @bernhard, I haven't used it before, but need to take a look. [pagebreak] is supported by PW ckeditor? Should be replaced with the "<pagebreak>" html tag supported by mpdf? Maybe the best / easiest solution to set pagebreak with the ckeditor. I have to test it. Thanks! Link to comment Share on other sites More sharing options...
bernhard Posted November 11, 2017 Share Posted November 11, 2017 [pagebreak] ist a custom tag I'm using it is then replaced by rockreplacer. I haven't tried but I guess <pagebreak> will not work inside ckeditor, but try it Link to comment Share on other sites More sharing options...
FrancisChung Posted November 21, 2017 Share Posted November 21, 2017 Has anyone come across this error before? It seems to start happening after my PW3 upgrade. I've had no problems with this module on PW 2.8.x.mPDF error: Some data has already been output to browser, can't send PDF file Update: It seems like we need to use an updated version of mpdf?https://stackoverflow.com/questions/46865306/mpdf-error-some-data-has-already-been-output-to-browser-cant-send-pdf-file-wh Update 2 : The error went away when I turned off debug in config.php Link to comment Share on other sites More sharing options...
Wanze Posted November 21, 2017 Author Share Posted November 21, 2017 @FrancisChung You could try to use the version of the module available on the "dev" branch, which uses a newer version of mPDF: https://github.com/wanze/Pages2Pdf/tree/dev I really should merge to master... could you report back if it works and if not, what kind of issues you are facing? Cheers Link to comment Share on other sites More sharing options...
FrancisChung Posted November 22, 2017 Share Posted November 22, 2017 @Wanze, I downloaded the latest version of mpdf and did a quick file comparison and the two versions looked vastly different. (So much so that the file comparison program 'hung') I didn't dare try merging or upgrading mpdf without any knowledge of its inner workings. There's another thread related to this issue below: Anyways, I managed to get it working but I now have a very strange bug going on. It seems that when I hover over our Site Logo, a Yellow Post it Note appears with the URL written on it? Very strange and not sure if anyone else is having this problem. Initially, I thought it had something to do with the Post it note chrome extension I had installed but uninstalling it made no difference. Link to comment Share on other sites More sharing options...
FrancisChung Posted November 22, 2017 Share Posted November 22, 2017 I've fixed the above issue. I've removed it the Anchor tag that wrapped the logo for the PDF version. Weird that it didn't show up before ... Link to comment Share on other sites More sharing options...
flydev Posted November 27, 2017 Share Posted November 27, 2017 @bernhard : by chance, maybe you used this module in the CRM you've made. Do you know if its possible to generate PDF document containing image charts (from the open-source chartJS lib) ? Link to comment Share on other sites More sharing options...
bernhard Posted November 27, 2017 Share Posted November 27, 2017 i've used mPDF standalone (my own module). and indeed i've had a project recently where i created reports with charts rendered by chartjs. i did a "hacky" solution where the charts are rendered, screenshot and integrated as PNG image by phantomjs. it's a bit slow but it was the best solution i could find - and the result looks very good 1 1 Link to comment Share on other sites More sharing options...
Macrura Posted December 26, 2017 Share Posted December 26, 2017 For anyone who is having the red x problem with images, I was able to solve these missing images by doing 2 things: 1) If you are on https, convert image references to absolute (i think this is because the library uses http when replacing image references ?) $rootPath = $pages->get(1)->httpUrl; $body = str_replace("/site/assets/", $rootPath . "site/assets/" , $page->body); 2) Manually create the temp folder ("WirePDF") inside site/assets/cache/ – this folder did not exist and therefore the core library was throwing image errors. Once these 2 things were completed, now the PDFs generate with the images correctly 6 Link to comment Share on other sites More sharing options...
Federico Posted January 2, 2018 Share Posted January 2, 2018 Hello PW community, very humble question (not found elsewhere here, but probably I did not search deeper yet): how to pass a pages array in admin module (say array of pages IDs out of an InputfieldPageListSelectMultiple) to wirePDF, to export them in the given order and in one single pdf? Here some code // Where to pass pages array to wirePDF ? // $page = $event->arguments[0]; $pdf = $this->modules->get("WirePDF"); // Define the main markup $pdf->markupMain = $this->config->paths->templates . '/book2pdf/default.php'; // Header markup, header is only printed if you provide the markup $pdf->markupHeader = $this->config->paths->templates . '/book2pdf/_header.php'; // The same goes for the footer $pdf->markupFooter = $this->config->paths->templates . '/book2pdf/_footer.php'; // You can override any of the module config options if you have other needs, e.g. $pdf->pageOrientation = 'L'; $pdf->headerFirstPage = '1'; $pdf->pageFormat = 'A3'; $pdf->bottomMargin = 10; $pdf->author = $this->user->name; $pdf->cssFile = $this->config->paths->templates . '/book2pdf/style.css'; // Saving the PDF file to disk //$pdf->save($this->config->paths->assets.'/test.pdf'); // ... or request download $pdf->download('variable-here.pdf'); thanks in advance! Link to comment Share on other sites More sharing options...
Macrura Posted January 2, 2018 Share Posted January 2, 2018 you can do like this: $pageArray = $this->wire('pages')->getById($_ids); $pdf->markupMain = ''; foreach($pageArray as $item) { $pdf->markupMain .= wireRenderFile($this->config->paths->templates . '/book2pdf/default.php', ["page" => $item]); } 1 Link to comment Share on other sites More sharing options...
Peter Knight Posted January 11, 2018 Share Posted January 11, 2018 In the screengrab attached my header is grey and has a height of 40mm. The text reading 12345 and everything after that is not part of my header and is wrapped in a DIV. Is there some trick to getting the content to start below the header and not overlap as such? My actuall CSS is very simple right now with only the header having a height. I could always give the body an absolute position but thought I'd ask first. Link to comment Share on other sites More sharing options...
jtborger Posted January 19, 2018 Share Posted January 19, 2018 Hi, First of all, thanks for this great module!! I have tried to search the forum and this topic, but no result... If Im overlooking something please excuse me... Im trying to find a way to set the orientation of a page in the template. I now try to do this by CSS with rotate and so, but its not working the way I want it to be. I also read in mPDF docs that this is an option when creating a page. In the global module configuration it can be set, but I wantt to set it for the template. Is this possible? Link to comment Share on other sites More sharing options...
Wanze Posted January 20, 2018 Author Share Posted January 20, 2018 @jtborger You could try to hook before Pages2Pdf::___createPDF() and change the page orientation based on the pages template: wire()->addHookBefore('Pages2Pdf::createPDF', function($event) { $page = $event->arguments('page'); $pages2pdf = $event->object; if ($page->template->name === 'your template') { $pages2pdf->getPDF()->set('pageOrientation', 'L'); } }); I'm not sure if it works though and I did not test if the above code is correct. Maybe it helps you to get started Cheers 1 Link to comment Share on other sites More sharing options...
jtborger Posted January 25, 2018 Share Posted January 25, 2018 Hi Wanze, Thanks for your reply and idea. I have tried to use it while generating the page with the image I'd like to have the right orientation, which can be different for each page...but this does not work for me. It would be very nice to be able to pass options to mpdf when in the pdf template I guess. I now have fixed it with CSS rotation, this works for me for the moment. Also, it's a bit counter intuitive to find that the footer is parsed before the main template; I tried to set some variables to get parsed in the footer, but this did not work.. Perhaps a quick fix to manage? Thanks again! Link to comment Share on other sites More sharing options...
itsberni Posted February 3, 2018 Share Posted February 3, 2018 Hi Wanze, very great module, very useful - thanks for making this. I think i'm doing some things wrong here because I couldn't get any ouput on the pdf. Only the header an footer - line is printed out. /xxx/xxx/site/templates/pages2pdf/_header.php /xxx/xxx/site/templates/pages2pdf/_footer.php I created a corresponding template in the pages2pdf-folder and defined it in the module configuration. But the only thing what i get is an empty page with this 2 lines above in the footer and the header. I've got a template/page where the content is only generated by the api. After the closing php-tag i tried the print out only the headline of this page with <?php $header = "Überschrift"; ?> <h1><?= $header ?></h1> No results at all. Even if i do <h1>Überschrift</h1> will give me an empty page. Where is my fault? Could you please give me an advice? Thanks a lot!!! Link to comment Share on other sites More sharing options...
webhoes Posted February 6, 2018 Share Posted February 6, 2018 I have implemented this module. It works great but it prints the page as it was when it got created (cached). On this page some moderations are done through editable fields. After that is needs to be printed as a pdf. Now I need to save the page before I can print. How can I either save the page before printing or don't use a cached version for printing? Link to comment Share on other sites More sharing options...
Federico Posted February 17, 2018 Share Posted February 17, 2018 Great module, I am using it extensively Couple of questions: - Do you know how to merge or prepend a multipage pdf file to the dynamically generated one? header and footers are repeated for all pages, whereas I am looking for something like a table of content - Is there any possibility to update the mpdf to the 7th version from the current 5.6? thanks a lot! 1 Link to comment Share on other sites More sharing options...
dragan Posted February 17, 2018 Share Posted February 17, 2018 Haven't used this module myself yet, but mpdf has a TOC function: https://mpdf.github.io/what-else-can-i-do/table-of-contents.html re: merge/prepend perhaps you can use this? https://mpdf.github.io/reference/mpdf-functions/importpage.html Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now