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
Requires
- php: >=5.3.3
- symfony/process: ~2.8|~3.0|~3.1
Requires (Dev)
- mikey179/vfsstream: ~1.5
- phpspec/phpspec: ~2.2
README
PHP library to parse PDF files to text. A wrapper for pdftotext.
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