Vipin Saini - 2019-05-16 05:22:11
Hi
Christian Vigh,
I hope you are doing well!
First of all thanks for this library and it is indeed very helpful if it works for me like it works for others.
Let me show you, what i am up to.
function output ( $message )
{
if ( php_sapi_name ( ) == 'cli' )
echo ( $message ) ;
else
echo ( nl2br ( $message ) ) ;
}
$file = 'sample' ;
$pdf = new PdfToText ( "$file.pdf" ) ;
output ( "Original file contents :\n" ) ;
output ( file_get_contents ( "$file.txt" ) ) ;
output ( "-----------------------------------------------------------\n" ) ;
output ( "Extracted file contents :\n" ) ;
output ( $pdf -> Text ) ;
I am using above code to read my PDF file. Unfortunately, every time i get non readable data therefore i request you to help to figure it out.
Thanks!