pdftk

PDFtk hanging on MacOS Sierra

感情迁移 提交于 2019-12-28 07:59:37
问题 PDFtk Server seems to be hanging indefinitely on MacOS Sierra. Looks similar to the problem it had on El Capitan. I'm trying to run this command: pdftk test1.pdf test2.pdf cat output out.pdf verbose And am getting no output, just an indefinite hang. Same with every other command I've tried. PDFtk --version: pdftk 2.02 a Handy Tool for Manipulating PDF Documents Copyright (c) 2003-13 Steward and Lee, LLC - Please Visit: www.pdftk.com This is free software; see the source code for copying

Adding current date to a signature image and adding it into an existing pdf

本秂侑毒 提交于 2019-12-25 00:33:54
问题 I have a signature image and want to add first the current date before it (on the left side) and then add this signature with date together to an existing pdf. The existing pdf is an application form with an area for the signature and date. What I have done so far is: magick \( -size 450x -gravity west -font NimbusSans-Regular label:23.10.2019 \) signature.png +append -strip -quality 100 signaturewithdate.png ^This adds the current date before the signature, works. Afterwards I convert the

Ruby/Rails: Traverse folders and parse metadata to seed DB

☆樱花仙子☆ 提交于 2019-12-24 23:22:17
问题 I have a bunch of documents that I'd like to index in a Rails application. I'd like to use a rake task of sorts to comb a directory hierarchy looking for files and capturing the metadata from those files to index in Rails. I'm not really sure how to do this in Ruby. I have found a utility called pdftk which can extract the metadata from the PDF files (much of what I'm indexing is PDFs) but I'm not sure how to capture the individual pieces of that data? For example, to grab the ModDate or each

Using PDFtk on a shared server

时光毁灭记忆、已成空白 提交于 2019-12-24 19:52:53
问题 I'm looking into using PDFtk, but I have several questions that I'm just going to bundle together. (Let me know if they should be asked separately.) How would I install it on my shared web server? I use WebHostingHub, and their servers run CentOS. How do you use it? I'm not sure how to run a command-line tool through PHP, which is what I assume I would need to do. I don't have any experience with running anything command-line as an automated process like this. (I use domPDF to convert form

PHPExcel create/style/save PDF Documentation

浪尽此生 提交于 2019-12-23 19:14:45
问题 I'm using the PHPExcel library in a couple of project and love the functionality it provides. Currently I needed to save as a PDF and found that PHPExcel can do this but I'm finding it rather hard to track down some examples or documentation on the process. Here are the links I have found: http://phpexcel.codeplex.com/wikipage?title=News%20archive http://www.devshed.com/c/a/PHP/PHP-Excel-Working-with-Workbook-and-PDF-Files/1/ Follow up question: I need the PDF to look and function as a form,

PDFTK not working to fill out pdf form created in livecycle

ぃ、小莉子 提交于 2019-12-21 04:39:39
问题 I created a form in livecycle es 2 and i am trying to use pdftk to fill out the form but it doesn't work. It says it fills it out successfully but when i try to open the pdf it just gives me an error saying "If this message is not eventually replaced by the proper contents of the document, your PDF viewer may not be able to display this type of document." Below is the code i am using to fill out the pdf <?php error_reporting(E_ALL); ini_set('display_errors', 1); $Clicks = "567"; $Impressions

Statically compile pdftk for Heroku. Need to split PDF into single page files

被刻印的时光 ゝ 提交于 2019-12-21 04:23:09
问题 So we're using heroku to host our rails application. We've moved to the cedar stack. This stack does not have the pdftk library installed. I contacted support and was told to statically compile it for amd64 ubuntu and include it in my application. This has proved more difficult than I thought. Initially I downloaded the package for ubuntu (http://packages.ubuntu.com/natty/pdftk), extracted it, and included the binary file as well as the shared libraries. I'm getting strange errors like:

Stamp PDF file with control for position of stamp file

别等时光非礼了梦想. 提交于 2019-12-18 11:13:27
问题 Does anyone know about stamping PDF file to PDF file and also controls for positioning PDF file stamp? I have a file orginal.pdf and logo.pdf . I want to stamp logo.pdf file to file orginal.pdf at the top left of file original.pdf . How can it be done with Ghostscript or pdftk ? 回答1: It can be done with Ghostscript plus pdftk, but it requires at least 2 different steps. AFAIK, you cannot directly control pdftk 's stamp placement. By default it puts the stamp on the center of the page, and at

How do you combine PDFs in ruby?

痞子三分冷 提交于 2019-12-18 11:07:56
问题 This was asked in 2008. Hopefully there's a better answer now. How can you combine PDFs in ruby? I'm using the pdf-stamper gem to fill out a form in a PDF. I'd like to take n PDFs, fill out a form in each of them, and save the result as an n -page document. Can you do this with a native library like prawn? Can you do this with rjb and iText? pdf-stamper is a wrapper on iText. I'd like to avoid using two libraries (i.e. pdftk and iText), if possible. 回答1: As of 2013 you can use Prawn to merge

Weird characters when filling PDF with PDFTk

柔情痞子 提交于 2019-12-18 07:02:00
问题 I'm using php with PDFTK on Ubuntu. When filling a PDF with data, I get weird characters for this letters with accents: á ó í . I'm using UTF-8 encoding: I checked with echo mb_check_encoding ($var, 'UTF-8') which outputs 1 - TRUE. Any idea what I can do? I also tried converting to ISO with utf8_decode, but still, no luck. Thanks 回答1: You're right, utf8_decode() will work for characters which can be encoded as Windows-1252 (i.e. U+0000–U+00FF). However it won't work for characters which can't