This project is read-only.

Doesn't work at all?

Feb 1, 2012 at 8:33 AM

I downloaded it, and tried it, and I get this error.

 

Deprecated: Assigning the return value of new by reference is deprecated in path\PDFMerger\fpdi\fpdi.php on line 88

Deprecated: Assigning the return value of new by reference is deprecated in path\PDFMerger\fpdi\fpdi_pdf_parser.php on line 239

Deprecated: Assigning the return value of new by reference is deprecated in path\PDFMerger\fpdi\fpdi_pdf_parser.php on line 244

Deprecated: Assigning the return value of new by reference is deprecated in path\PDFMerger\fpdi\pdf_parser.php on line 104

Deprecated: Assigning the return value of new by reference is deprecated in path\PDFMerger\fpdi\pdf_parser.php on line 217

Deprecated: Assigning the return value of new by reference is deprecated in path\PDFMerger\fpdi\pdf_parser.php on line 297

Deprecated: Assigning the return value of new by reference is deprecated in path\PDFMerger\fpdi\pdf_parser.php on line 448

Fatal error: Call to a member function merge() on a non-object in path\download-pdf-all.php on line 231

Feb 1, 2012 at 8:37 AM

The last fatal error I fixed, stupid typo. But it still doesn't work.

 

Fatal error: Uncaught exception 'Exception' with message 'Error outputting PDF to 'file'.' in path\PDFMerger\PDFMerger.php:124
Stack trace:
#0 path\download-pdf-all.php(231): PDFMerger->merge('file', 'path')
#1 {main}
  thrown in path\PDFMerger\PDFMerger.php on line 124

Feb 13, 2012 at 3:56 PM

hello. I have a same problem. It's problem in PDFmerger on line 118, where FPDI returns empty string (which is ok), but Merger interprets it as false. 
I suggest fix that part or use another way:

$fileString = $merger->merge('string',$filename);

file_put_contents($filename, $fileString);

Aug 8, 2012 at 9:00 PM

on line 1042 in fpdf.php, I changed to

case 'F':
	//Save to local file
	$f=fopen($name,'wb');
	if(!$f){
	    $this->Error('Unable to create output file: '.$name);
            return false;
	}
	fwrite($f,$this->buffer,strlen($this->buffer));
	fclose($f);
        return true;
        break;

 

seemed to fix it.

Aug 27, 2012 at 12:38 AM

Just as a note, you can fix errors like:

Deprecated: Assigning the return value of new by reference is deprecated in [...]


by replacing in files  "=& new" assignments with "= new" assignments (in PHP5 objects are passed by reference by default).

Jun 29, 2013 at 9:32 PM
Edited Jun 29, 2013 at 9:33 PM
Does anyone know how to fix the following error?
Strict Standards: Declaration of FPDF_TPL::Image() should be compatible with that of FPDF::Image() in path\fpdi\fpdf_tpl.php on line 409

thanks in advance!
Apr 4, 2016 at 2:04 PM
Just change line 269 on fpdf_tpl.php to :
    function Image($file, $x='', $y='', $w=0, $h=0, $type='', $link='', $align='', $resize=false, $dpi=300, $palign='', $ismask=false, $imgmask=false, $border=0) {