Problem with PDF Merger (download & browser option)

Nov 21, 2013 at 2:02 PM
Dear all,
i downloaded pdf merger and i tried the example sample.php:
<?php
include 'PDFMerger.php';
$pdf = new PDFMerger;
$pdf->addPDF('samplepdfs/one.pdf', '1, 3, 4')
    ->addPDF('samplepdfs/two.pdf', '1-2')
    ->addPDF('samplepdfs/three.pdf', 'all')
    ->merge('download','testdown.pdf');
    //REPLACE 'file' WITH 'browser', 'download', 'string', or 'file' for output options
    //You do not need to give a file path for browser, string, or download - just the name.
?>
The system shows me the file to download. I click "yes", download the merged file but i cannot open with adobe reader . The message i received is :
because it is either not a supported file type or because the file has been damaged (for example, it was sent an email attachment and wasn't correctly decoded)

If i use "browser option", i have in my browser this error:

%PDF-1.7 3 0 obj <> endobj 4 0 obj <> stream x�3R��2�35W(�T0P�R0T(�Y@���@QC= PA�J��� �1Tp�W� ���� endstream endobj 5 0 obj <> endobj 6 0 obj <> stream x�3R��2�35W(�T0P�R0T(�Y@���@QC= PA�J��� �1Rp�W� ���� endstream endobj 7 0 obj <> endobj 8 0 obj <> stream x�3R��2�35W(�*T0P�R0T(�Y@���@QC= PA�J��� �1Vp�W� ���� endstream endobj 9 0 obj <> endobj 10 0 obj <> stream x�3R��2�35W(�T0P�R0T(�Y@���@QC= PA�J��� �1Qp�W� ���� endstream endobj 11 0 obj <> endobj 12 0 obj <> stream x�3R��2�35W(�T0P�R0T(�Y@���@QC= PA�J��� �1Up�W� ���� endstream endobj 13 0 obj <> endobj 14 0 obj <> stream x�3R��2�35W(�T0P�R0T(�Y@���@QC= PA�J��� �1Sp�W� ���� endstream endobj 15 0 obj <> endobj 16 0 obj <> stream x�3R��2�35W(�T0P�R0T(�Y@���@QC= PA�J��� �1Wp�W� ���� endstream endobj 1 0 obj <> endobj 17 0 obj <>/ProcSet [/PDF /Text ] >>/Length
and other characters..
Could you help me?
Thanks in advance.
Daniele
Mar 24, 2014 at 2:48 AM
You can actually merge PDF documents from any versions easily.