mardi 5 mars 2019

Laravel: How to make the converted pdf-to-Text file in a readable format?

I managed to convert the pdf-to-text file but when i echo the converted content, I am getting some un-readable text as:-

Ă$0.ipton.A\n
muGp$Spt$.T\n
PpIptpTጇ\n
1/$0Ԇption\n
Amount\n
GST\n
ᄅi0/\n
VȄ.NutpoomptOCNp$oE0Qoa0y\n
100o1ᴇttQoauဇ\n
auOpt0.ဉn.t0ᴉVI1o3026\n
⌇Gp༝.ဇ:o(03)o9926o9999\n
Fu$NiCGp:o(03)o9926o9977\n
VBno67o004o497o607\n
उउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउo\n
उउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउउबUTmTVnDIਯoBVaVਁEउउoउउउउउउउउउउउउउउo\n
1Vఱoఔᤰooo-ooEVIDoInoFUᤙooo\n
Tu㌉ITO.Cጇon.A\n
Du0p:\n
Eugp:\n
INVOIᘗ\n
Quantity\n
1/1\n
$0.00\n

My PDF file is in basic English, but when it gets converted, I am getting the above output.Not too sure how to convert this text in English Readable Format.

$path = public_path('/pdftotext/'. $name);  *//getting the file location*
$reader = new \Asika\Pdf2text; 
$output = $reader->decode($path); *//decoding the file*
dd($output); *// the output I mentioned above, i get it here.*



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire