vuthaihoc/pdf-parser

PHP library to parse text from PDF files, use symfony/process 3.x

v0.1.2 2016-06-24 06:43 UTC

This package is auto-updated.

Last update: 2024-03-28 22:15:10 UTC


README

PHP library to parse PDF files to text. A wrapper for pdftotext.

Build Status

Installation

Via Composer

composer require wrseward/pdf-parser

pdftotext binary

Debian / Ubuntu

apt-get install poppler-utils

RedHat / CentOS

yum install poppler-utils

OS X

brew install xpdf

Verify your installation / Get the path of the binary

which pdftotext

Usage

$parser = new \Wrseward\PdfParser\Pdf\PdfToTextParser('/usr/bin/pdftotext');
$parser->parse('/path/to/file.pdf');
echo $parser->text();

Running tests

./vendor/bin/phpspec run

License

MIT