mgufrone / pdf-to-html

PDF to HTML PHP Class using Poppler-Utils
MIT License
175 stars 88 forks source link

pdftohtml conversion only converting the 1st page or even less than that. #47

Open joydipnath opened 6 years ago

joydipnath commented 6 years ago

\Gufy\PdfToHtml\Config::set('pdftohtml.bin', '/usr/bin/pdftohtml'); \Gufy\PdfToHtml\Config::set('pdfinfo.bin', '/usr/bin/pdfinfo'); $pdf = new \Gufy\PdfToHtml\Pdf('/var/www/html/test_big/test.pdf'); $html = $pdf->html(); Thats my code. Its converting but only the 1st page for some cases and even less than that .

hussain-t commented 6 years ago

I also have the same issue.

When I debug the code, sometimes the $id argument in the following function is null hence it throws the error "Child '$id' not found in this node." in a recursive loop.

public function getChild($id) { if ( ! isset($this->children[$id])) { throw new ChildNotFoundException("Child '$id' not found in this node."); } return $this->children[$id]['node']; }

Thanks.