You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is maybe more of a PHP question than pdfparser one but here it goes anyway:
Important part of my code:
$parser = new \Smalot\PdfParser\Parser();
$pdf = $parser->parseFile($file_path);
$pages = $pdf->getPages();
foreach ($pages as $page) {
$text = $page->getText();
$stringWithoutNewLine = str_replace("\n"," ",escapeshellarg($text));
//some more code
}
And this returns the error in the title. Sure enoguh, I think some of the pages in my .pdf have only images, no text.
I would like to get an empty string if there is no text on the page.
The text was updated successfully, but these errors were encountered:
This is maybe more of a PHP question than pdfparser one but here it goes anyway:
Important part of my code:
And this returns the error in the title. Sure enoguh, I think some of the pages in my .pdf have only images, no text.
I would like to get an empty string if there is no text on the page.
The text was updated successfully, but these errors were encountered: