Skip to content

A simple and clean PHP wrapper over the pdftotext binary to allow for efficient and reliable parsing of text from PDF files.

License

Notifications You must be signed in to change notification settings

wrseward/pdf-parser

Repository files navigation

wrseward/pdf-parser

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

About

A simple and clean PHP wrapper over the pdftotext binary to allow for efficient and reliable parsing of text from PDF files.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages