Skip to content
This repository has been archived by the owner on Jun 12, 2018. It is now read-only.
/ FormFillFlatten Public archive

RESTful web service for filling field values in a PDF template and then 'flattening' the PDF so the fields can no longer be edited.

License

Notifications You must be signed in to change notification settings

pwaring/FormFillFlatten

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FormFillFlatten is a RESTful web service which allows users to upload a
PDF template containing form elements, together with the values which
should used to fill those placeholders. FFF populates the form fields
and returns a 'flattened' PDF, which allows no further editing.

This software uses iText, which is licensed under the AGPL, and as such
FormFillFlatten is also AGPL-licensed. A copy of the AGPL can be found
in the file LICENCE in the root directory of this project.

REQUIREMENTS

* Java 1.6.0 or later (tested with OpenJDK 1.6.0_20)
* iText 5.0.6 or later (tested with 5.0.6)
* JSON-java
* PHP 5.2.0 or later (tested with 5.3.2)
* Web server which supports PHP (Apache 2.2.x recommended)

You *may* be able to get this working on Windows or Mac OS X, but you
will have a much smoother ride using a Debian/Ubuntu server running
Apache and mod_php.

EXTRACTING DATA FIELDS

In order to provide a mapping of field names to values, you must first
find out what the field names are for the PDF. The easiest way to do this
is via the pdftk command, which is available for the majority of Linux
distributions.

The following command will show you the type and name of each form field
in a PDF:

pdftk input.pdf dump_data_fields

Example output might be:

--
FieldType: Text
FieldName: Text29
FieldFlags: 0
FieldValue: Default value for field
FieldJustification: Left
--

All you need to care about is the FieldName value, as this is the unique
name for the field. It may have a sensible name or an auto-generated one
such as Text29.

About

RESTful web service for filling field values in a PDF template and then 'flattening' the PDF so the fields can no longer be edited.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published