From b0542b730bb88cc60131ecca9ea297e28949fcc5 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Wed, 1 Mar 2006 16:21:19 +0000 Subject: [PATCH] =?UTF-8?q?Fix:=20on=20ne=20pouvait=20voir=20que=20la=20pr?= =?UTF-8?q?emi=E8re=20page=20de=20l'aper=E7u?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/comm/propal/apercu.php | 6 ++++-- htdocs/commande/apercu.php | 6 ++++-- htdocs/compta/facture/apercu.php | 7 +++++-- 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/htdocs/comm/propal/apercu.php b/htdocs/comm/propal/apercu.php index a08981bff25..9f3c986bd13 100644 --- a/htdocs/comm/propal/apercu.php +++ b/htdocs/comm/propal/apercu.php @@ -207,6 +207,7 @@ if ($_GET["propalid"] > 0) { // Chemin vers png aperçus $relativepathimage = "${propalref}/${propalref}.pdf.png"; $relativepathimagebis = "${propalref}/${propalref}.pdf.png.0"; + $relativepathimagebis2 = "${propalref}/${propalref}.pdf.png.1"; $fileimage = $file.".png"; // Si PDF d'1 page $fileimagebis = $file.".png.0"; // Si PDF de plus d'1 page @@ -257,7 +258,7 @@ if ($_GET["propalid"] > 0) { $description = imagick_faileddescription( $handle ) ; print "handle failed!
\nReason: $reason
\nDescription: $description
\n"; } - imagick_writeimage( $handle, $file .".png"); + imagick_writeimages( $handle, $file .".png"); } else { $langs->load("other"); print ''.$langs->trans("ErrorNoImagickReadimage").''; @@ -297,7 +298,8 @@ if (file_exists($fileimage)) // Si fichier png PDF de plus d'1 page trouvé elseif (file_exists($fileimagebis)) { - print ''; + print '

'; + print '

'; } diff --git a/htdocs/commande/apercu.php b/htdocs/commande/apercu.php index 6849769c5ab..dfff2e522bd 100644 --- a/htdocs/commande/apercu.php +++ b/htdocs/commande/apercu.php @@ -181,6 +181,7 @@ if ($_GET["id"] > 0) { // Chemin vers png aperçus $relativepathimage = "${commanderef}/${commanderef}.pdf.png"; $relativepathimagebis = "${commanderef}/${commanderef}.pdf.png.0"; + $relativepathimagebis2 = "${commanderef}/${commanderef}.pdf.png.1"; $fileimage = $file.".png"; // Si PDF d'1 page $fileimagebis = $file.".png.0"; // Si PDF de plus d'1 page @@ -231,7 +232,7 @@ if ($_GET["id"] > 0) { $description = imagick_faileddescription( $handle ) ; print "handle failed!
\nReason: $reason
\nDescription: $description
\n"; } - imagick_writeimage( $handle, $file .".png"); + imagick_writeimages( $handle, $file .".png"); } else { $langs->load("other"); print ''.$langs->trans("ErrorNoImagickReadimage").''; @@ -289,7 +290,8 @@ if (file_exists($fileimage)) // Si fichier png PDF de plus d'1 page trouvé elseif (file_exists($fileimagebis)) { - print ''; + print '

'; + print '

'; } diff --git a/htdocs/compta/facture/apercu.php b/htdocs/compta/facture/apercu.php index 09ce8853758..ffdcbcf3fc9 100644 --- a/htdocs/compta/facture/apercu.php +++ b/htdocs/compta/facture/apercu.php @@ -143,6 +143,8 @@ if ($_GET["facid"] > 0) // Chemin vers png aperçus $relativepathimage = "${facref}/${facref}.pdf.png"; $relativepathimagebis = "${facref}/${facref}.pdf.png.0"; + $relativepathimagebis2 = "${facref}/${facref}.pdf.png.1"; + $fileimage = $file.".png"; // Si PDF d'1 page $fileimagebis = $file.".png.0"; // Si PDF de plus d'1 page @@ -200,7 +202,7 @@ if ($_GET["facid"] > 0) print "handle failed!
\nReason: $reason
\nDescription: $description
\n"; } - imagick_writeimage( $handle, $file .".png"); + imagick_writeimages( $handle, $file .".png"); } else { @@ -239,7 +241,8 @@ if (file_exists($fileimage)) // Si fichier png PDF de plus d'1 page trouvé elseif (file_exists($fileimagebis)) { - print ''; + print '

'; + print '

'; }