Download the PHP package randomstate/camelot-php without Composer
On this page you can find all versions of the php package randomstate/camelot-php. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download randomstate/camelot-php
More information about randomstate/camelot-php
Files in randomstate/camelot-php
Package camelot-php
Short Description PHP Wrapper library for interfacing with the Camelot PDF table extraction library built in Python
License MIT
Informations about the package camelot-php
randomstate/camelot-php
A PHP wrapper for Camelot, the python PDF table extraction library
Installation
composer require randomstate/camelot-php
Usage
The package adheres closely with the camelot CLI API Usage.
Default output is in CSV format as a simple string. If you need to parse CSV strings we recommend the league/csv
package (https://csv.thephpleague.com/)
Advanced Processing
Saving / Extracting
Note: No Camelot operations are run until one of these methods is run
Set Format
Specify Page Numbers
$camelot->pages('1,2,3-4,8-end')
Reading encrypted PDFs
$camelot->password('my-pass')
Processing background lines
$camelot->stream()->processBackgroundLines()
Visual debugging
$camelot->plot()
Specify table areas
Specify table regions
Specify column separators
$camelot->stream()->setColumnSeparators($x1,$x2...)
Split text along separators
$camelot->split()
Flag superscripts and subscripts
$camelot->flagSize()
Strip characters from text
$camelot->strip("\n")
Improve guessed table areas
$camelot->setEdgeTolerance(500)
Improve guessed table rows
$camelot->setRowTolerance(15)
Detect short lines
$camelot->lineScale(20)
Shift text in spanning cells
$camelot->shiftText('r', 'b')
Copy text in spanning cells
$camelot->copyTextSpanningCells('r', 'b')
License
MIT. Use at your own risk, we accept no liability for how this code is used.